Method and system for debugging an electronic system

ABSTRACT

Techniques and systems for debugging an electronic system having instrumentation circuitry included therein are disclosed. The techniques and systems facilitate analysis, diagnosis and debugging fabricated hardware designs at a Hardware Description Language (HDL) level. Although the hardware designs (which were designed in HDL) have been fabricated in integrated circuit products with limited input/output pins, the invention enables the hardware designs within the integrated circuit products to be comprehensively analyzed, diagnosed, and debugged at the HDL level at speed. The ability to debug hardware designs at the HDL level facilitates correction or adjustment of the HDL description of the hardware designs.

CROSS-REFERENCE TO RELATED APPLICATIONS

This application claims the benefit of: (i) U.S. Provisional PatentApplication No. 60/168,266, filed Nov. 30, 1999, and entitled“INTERACTIVE DEBUGGING OF HDL SOURCE CODE”, and which is herebyincorporated by reference herein; and (ii) U.S. Provisional PatentApplication No. 60/230,068, filed Aug. 31, 2000, and entitled “HDL-BASEDHARDWARE DEBUGGING”, and which is hereby incorporated by referenceherein.

BACKGROUND OF THE INVENTION

1. Field of the Invention

The present invention relates to electronic systems and, moreparticularly, to debugging of electronic systems.

2. Description of the Related Art

Electronic systems are designed by designers to operate in specificways. Electronic systems are systems that contain digital and/or analogelectronic components connected together to perform specific operationsor functions. Besides the electronic components, electronic systems mayalso include software. Once designed, the electronic systems may need tobe debugged. Debugging electronic systems is a process which involvesdetection, diagnosis, and correction of functional failures. In thedetection step, the designer of the electronic system observes afunctional failure. When the designer is able to gather enoughinformation about the incorrect behavior of the electronic system, thedesigner of the electronic system can draw the necessary conclusions todiagnose the functional failure. For correction of the functionalfailure, a fix is applied and subsequently tested. When the design isprovided in a Hardware Description Language (HDL), such a fix may be atextual change to the HDL description of the electronic system.

In general, debugging has conventionally been performed by variousdifferent approaches. In particular, debugging has been performed bycomputer software debugging, hardware description language functionalverification, hardware logic level analysis, or hardware behavioralsource level emulation. These different approaches are discussed below.

Computer software debugging is conventionally performed using a computersoftware debugger. A computer software debugger is a software tool thatallows a software developer to control the execution of a runningcomputer software program by setting break-points, sequentiallysingle-stepping through the execution of the computer software program,and looking at the program's state by examining and displaying variablesand expressions. One example of such a software debugging tool is theGNU Debugger (GDB), which can be obtained from Red Hat, Inc. inSunnyvale, Calif.

Software debuggers usually offer interactive debugging of softwareprograms which are sequentially executed on computers. However, somesoftware debuggers also support limited concurrency such as threadedprogram execution. Some software debuggers support debugging programswritten at different levels of abstraction from high-level computerlanguages such as C++ down to assembler code and/or machine code. Toassist with debugging of programs written in high-level computerlanguages, the software debugging system can add extra debug information(e.g., symbolic names and references to source code) to the compiledcode during compilation of the computer software program. In combinationwith in-circuit emulators, software debuggers may provide a limitedcapability to analyze the underlying Central Processing Unit (CPU) ofthe computer executing the computer software program. A majordisadvantage of software debuggers is, however, that they cannot be usedfor efficiently debugging general hardware of electronic systems.

Hardware description language functional verification is used to verifythat the parts of an electronic system which are described using HDLmatch their functional specification. Such functional verification canbe achieved through functional simulation or formal verification.

Functional simulation is performed by a functional simulator. Afunctional simulator is a software program that runs on a host computerand simulates the operation of an electronic system using its HDLdescription. Examples of functional simulators include VCS and VSS fromSynopsys, Inc. in Mountain View, Calif., and ModelSim from MentorGraphics Corp. in Wilsonville, Oreg. To increase simulation performancesome functional simulators additionally make use of special purposehardware which acts as a co-processor and accelerates the simulation. Anexample of a hardware-accelerated functional simulator is the Hammersystem from Tharas Systems, Inc. in Santa Clara, Calif. Unfortunately,one major disadvantage of functional simulation is the need forsimulation models. In order to be able to simulate, there must exist asimulation model with the proper functional behavior for each componentof the HDL design for the electronic system. For some components suchsimulation models may not be readily available and must be generated.Additionally, the HDL design must be stimulated by a testbench. Sincethe ideal testbench must correctly and exhaustively match the behaviorof the target environment, creation of a testbench can be very difficultand time consuming. On the other hand, a testbench that is too simplewill not provide the necessary coverage to find all the design errors.Although functional simulation is useful, using functional simulation todebug design errors is too burdensome. Not only are the testbenchesdifficult to create, but also the more complex the HDL design is, thelower the performance of functional simulation. For state-of-the-art HDLdesigns simulation is now a million times slower than the fabricatedhardware. Hardware-acceleration can typically speedup functionalsimulation by a factor on the order of one-hundred. Accordingly, its lowperformance makes it impractical to use functional simulation either todebug real-time applications or to concurrently debug hardware andsoftware of complex electronic systems.

Formal verification is performed by a formal verification tool. Formalverification can help with the problem of incomplete coverage infunctional simulation due to testbench limitations. One approach checksthe HDL description for properties. Such properties may be explicitlyprovided by the designer of the electronic system or implicitlyextracted from the HDL description by the formal verification tool. Anexample of such a formal verification tool is Solidify from Averant,Inc. in Sunnyvale, Calif. One disadvantage of formal verification isthat it is impractical to use to re-produce functional failures observedin a running electronic system.

Both techniques, functional simulation and formal verification, have themajor disadvantage that they do not operate on fabricated hardware.Instead, both techniques operate on a model of the electronic system anda model of the environment in which the electronic system runs, i.e., atestbench. Thus, their use is limited to debugging design errors. Assuch, neither technique is applicable for debugging manufacturingfaults, environment errors, timing errors and/or tool errors. Also,inadequacies in the testbench have the potential to hide or introducedesign errors in the HDL design during functional simulation which canlater, when the HDL design is fabricated, show up as functional failuresof the running electronic system.

Hardware logic level analysis is a technique that works at the logiclevel of a fabricated electronic system. The logic level of abstractionis also referred to as gate-level. Since electronic systems have beendesigned at the logic level for many years (for example using schematicentry of logic gates and flip-flops), there exists a wide variety ofdifferent techniques for debugging at logic level, including: digitallogic analyzers, in-circuit emulators, Design-For-Test (DFT) techniques,and hardware emulation, each of these different techniques are discussedbelow.

Digital logic analyzers operate to probe a limited number of digitalsignals and record their logic values. Probing is accomplished byphysically connecting probes of the digital logic analyzer to exposedpins and/or circuitry on the fabricated design. Recording is controlledby trigger conditions, which are conditional expressions built upon thevalues of the recorded signals provided by the probes. The values forthe recorded signals are stored in dedicated memory inside the digitallogic analyzer so as to be available for subsequent display. Digitallogic analyzers can be external devices or blocks embedded inside thedigital circuits of an electronic system. An example of an externaldigital logic analyzer is the Agilent 16715A from Agilent Technologies,Inc. in Palo Alto, Calif. Examples of embedded logic analyzers areSignalTap from Altera Corporation in San Jose, Calif., or ChipScope fromXilinx, Inc. in San Jose, Calif. Another example of an embedded logicanalyzer was presented at the 1999 IEEE International Test Conference byBulent Dervisoglu in “Design for Testability: It is time to deliver itfor Time-to-Market”. Since embedded logic analyzers are added to thecircuitry of the design, they can probe internal signals. Thus, embeddeddigital logic analyzers overcome the limited access to internal signalsproblem of external logic analyzers because access to the internalsignals is not restricted by the pins of the fabricated circuits.

An in-circuit emulator is a specialized piece of hardware that connectsto a CPU for debugging the CPU and the software that runs on the CPU. Anexample of an in-circuit emulator is visionICE from Windriver inAlameda, Calif. However, since in-circuit emulators only work for thespecific target CPU for which they were built, in-circuit emulators areinappropriate for debugging general digital circuits.

DFT techniques, such as boundary scan and built-in self test, provideaccess to the internal registers of a running fabricated digitalcircuit. An example of such technique is described in the IEEE 1149.1JTAG standard available from the Institute of Electrical and ElectronicEngineers in Piscataway, N.J. DFT techniques are also to described in“Digital Logic Testing and Simulation” by Alexander Miczo, published byWiley, John and Sons Inc., 1985. DFT techniques were originallydeveloped for and applied to testing of manufacturing faults and havethe major disadvantage that they do not relate back to the HDLdescription.

Hardware emulation systems map a synthesized HDL design onto specialemulation hardware. Such emulation hardware comprises manyre-programmable FPGA devices and/or special purpose processors. Theemulation hardware then executes a model of the HDL design. Thushardware emulation has the same disadvantage as functional simulation,namely, that it works on a model of the electronic system and not on thefabricated hardware. As a result, hardware emulation systems are limitedto design error debugging, and cannot be used for diagnosingmanufacturing faults, tool errors, timing errors, etc. An example ofsuch a hardware emulation system is System Realizer from QuickturnSystems, in San Jose, Calif. Specially built prototyping systemscomprising FPGAs/PLDs can also be seen as hardware emulation systems.Since hardware emulation is usually much faster than functionalsimulation, hardware emulation systems may enable use of the softwarethat is supposed to run on the HDL design to be used as a testbench.Even so, hardware emulation typically runs at speeds below one MegaHertz(MHz) while the HDL design is supposed to run at many hundred MegaHertz.In some cases the emulator speed may allow the user to connect the HDLdesign to the target environment which makes the design of testbenchesunnecessary. Even so, with the high speeds of state-of-the-art HDLdesigns, hardware emulation is not capable of debugging the majority ofreal-time applications. Another disadvantage is that the specialsynthesis, mapping, and multi-chip partitioning steps required to bringan HDL design into a hardware emulation system are very complicated andtime consuming.

A major drawback of all logic level debugging techniques is that theywork at the logic level of abstraction. Since the HDL-based designmethodology of electronic systems is much more efficient for todayscomplex designs, HDL designs have largely replaced logic level designs.Application of logic level debugging techniques to HDL designmethodology is highly inefficient. Since logic level debugging does notrelate back to the HDL description, it normally would not provide thedesigner of the electronic system with sufficient information tocorrectly diagnose a functional to failure.

Hardware behavioral source level emulation provides hardware emulationof source level designs. One technique for debugging HDL designsdescribed at the behavioral level HDL using hardware emulation isdescribed in “Interaktives Debugging algorithmischerHardware-Verhaltensbeschreibungen mit Emulation” by Gernot H. Koch,Shaker Verlag, Germany, 1998. Some of which is also described in Koch etal., “Breakpoints and Breakpoint Detection in Source Level Emulation,”ACM Transactions on Design Automation of Electronic Systems, Vol. 3, No.2, 1998. The therein described technique is referred to as Source LevelEmulation (SLE) and offers an approach for emulating HDL designs,however only if such designs are described in behavioral VHDL. Duringbehavioral synthesis a behavioral HDL design is enhanced for debuggingby generating and adding additional circuitry for break-point detection.The behavioral synthesis tool writes out synthesized VHDL which containsa register transfer level description of the enhanced HDL design. Theregister transfer level description is then synthesized, mapped, andmulti-chip partitioned into the emulation hardware. During hardwareemulation with a hardware model of the HDL design, the user is able toexamine particular variables in the behavioral HDL description.

Control is provided via break-points which are detected using theadditional circuitry inside the running hardware model. Break-points inSLE have a very specific meaning. In particular, such break-points areclosely tied to behavioral operations in the data-flow of the behavioralHDL description, and are associated with particular states of acontroller which is generated by the behavioral synthesis. Additionally,break-points can be made conditioned upon particular values of data-pathregisters. When a break-point is detected, the execution of the hardwaremodel is stopped. This is done by halting some or all of the systemclocks and prevents the registers from changing their current values.Once halted, internal registers can be read. These registers form ascan-chain such that their values can be read by an emulation debuggingtool.

Examination of variables in the behavioral HDL description is done intwo ways. For variables which are mapped by the behavioral synthesisinto registers in the hardware model, their values can be read andrelated back to HDL identifiers. This is done using map files which keeptrack of the transformations in behavioral synthesis, register transferlevel synthesis, mapping, and multi-chip partitioning. For variableswhich have not been mapped to registers in the hardware model, theirvalues are computed using a functional model of the behavioral HDLdesign. This functional model is created during behavioral synthesis andrequires the existence of functional models of its components. Thevalues, either read or computed, are then displayed in the behavioralHDL description. Optionally, by overwriting some or all of the registersof the hardware model while the hardware model is halted, the behaviorof the HDL design can be modified once the execution of the hardwaremodel is resumed.

Although source level emulation provides a debugging method which worksat the level of the HDL description (in this case behavioral VHDL), ithas various drawbacks which limits its use in practice. Several of thedrawbacks are as follows. First, enhancements for source level emulationmust be done inside a behavioral synthesis tool, since it needs specialinformation about the behavioral HDL design which is only availableduring the behavioral synthesis process. Second, source level emulationdoes not allow the designer to perform customization. For example, adesigner is not able to select trade-offs between hardware overhead anddebugging support. Third, source level emulation cannot handle HDLdescriptions on levels of abstraction other than the one provided bybehavioral VHDL. Explicitly, source level emulation is not applicablefor the most commonly used levels of abstraction of RTL HDL andgate-level HDL. Fourth, source level emulation supports neitherhierarchy nor re-use of pre-designed blocks. Fifth, there are variouslimitations and difficulties in relating registers back to behavioralHDL source code. Sixth, in order to examine the state of the hardwaremodel, it is required that some or all of the system clocks be haltedand the hardware stopped, which makes source level emulationinapplicable for debugging the majority of today's electronic systemswhich are not to be stopped.

Thus, there is a need for efficient and effective approaches fordebugging HDL-based electronic system designs.

SUMMARY OF THE INVENTION

Broadly speaking, the invention relates to techniques and systems fordebugging an electronic system having instrumentation circuitry includedtherein. The invention facilitates analysis, diagnosis and debuggingfabricated hardware designs at a Hardware Description Language (HDL)level. Although the hardware designs (which were designed in HDL) havebeen fabricated in integrated circuit products with limited input/outputpins, the invention enables the hardware designs within the integratedcircuit products to be comprehensively analyzed, diagnosed, and debuggedat the HDL level at speed. The ability to debug hardware designs at theHDL level facilitates correction or adjustment of the HDL description ofthe hardware designs.

The invention can be implemented in numerous ways including, a method,system, device, and a computer readable medium. Several embodiments ofthe invention are discussed below.

As a method for debugging an electronic system having instrumentationcircuitry included therein, wherein the electronic system is describedwith an HDL, one embodiment of the invention includes at least the actsof: activating certain design visibility, design patching or designcontrol aspects of the instrumentation circuitry available for examiningor modifying the electronic system via the instrumentation circuitry;determining configuration information based on the certain designvisibility, design patching or design control aspects that areactivated; configuring the instrumentation circuitry in accordance withthe configuration information; receiving debug data from the configuredinstrumentation circuitry operating within the integrated circuitproduct; translating the debug data into HDL-related debug information;and relating the HDL-related debug information to the HDL description.

As a method for debugging an integrated circuit product havinginstrumentation circuitry included therein, wherein the integratedcircuit product was designed with a high-level HDL description, oneembodiment of the invention includes at least the acts of: activatingcertain aspects available for examining or modifying by theinstrumentation circuitry; determining configuration information basedon the certain aspects that are activated; configuring theinstrumentation circuitry in accordance with the configurationinformation; receiving debug data from the configured instrumentationcircuitry operating within the integrated circuit product; translatingthe debug data into HDL-related debug information; relating theHDL-related debug information to the high-level HDL description;thereafter retrieving circuit status information for the integratedcircuit product via the instrumentation circuitry; and displaying stateinformation concerning the integrated circuit product based on theretrieved circuit status information.

As a computer readable medium including at least computer program codefor debugging an electronic system having instrumentation circuitryincluded therein, wherein the electronic system is described with anHDL, one embodiment of the invention includes at least: computer programcode for activating certain design visibility, design patching or designcontrol aspects of the instrumentation circuitry available for examiningor modifying the electronic system via the instrumentation circuitry;computer program code for determining configuration information based onthe certain design visibility, design patching or design control aspectsthat are activated; computer program code for configuring theinstrumentation circuitry in accordance with the configurationinformation; computer program code for receiving debug data from theconfigured instrumentation circuitry operating within the integratedcircuit product; computer program code for translating the debug datainto HDL-related debug information; and computer program code forrelating the HDL-related debug information to the HDL description.

Other aspects and advantages of the invention will become apparent fromthe following detailed description taken in conjunction with theaccompanying drawings which illustrate, by way of example, theprinciples of the invention.

BRIEF DESCRIPTION OF THE DRAWINGS

The invention will be readily understood by the following detaileddescription in conjunction with the accompanying drawings, wherein likereference numerals designate like structural elements, and in which:

FIG. 1A is a block diagram of a hardware debugging system according toone embodiment of the invention;

FIG. 1B is a block diagram of a hardware debugging system according toanother embodiment of the invention;

FIG. 2 is a flow diagram of basic instrumentation processing accordingto one embodiment of the invention;

FIG. 3 is a block diagram of an instrumentation system according to oneembodiment of the invention;

FIGS. 4A and 4B are flow diagrams of detailed design instrumentationprocessing according to one embodiment of the invention;

FIG. 5A is a flow diagram of selection processing according to oneembodiment of the invention;

FIG. 5B is a flow diagram of break-point processing according to oneembodiment of the invention;

FIG. 5C is a flow diagram of explicit trigger condition selectionprocessing according to one embodiment of the invention;

FIG. 5D is a flow diagram of sampling signal selection processingaccording to one embodiment of the invention;

FIG. 6 is a diagram of a design instrumentation database according toone embodiment of the invention;

FIG. 7A is a block diagram of an instrumentation system according to oneembodiment of the invention;

FIG. 7B is a diagram of a hard block resolution system according to oneembodiment of the invention;

FIG. 8 is a block diagram of a representative Design InstrumentationCircuit (DIC) according to one embodiment of the invention;

FIG. 9 describes a representative generic configurable circuitry whichcan implement design sampling and design patching according to oneembodiment of the invention;

FIG. 10 illustrates a representative generic configurable triggerdetection circuit according to one embodiment of the invention;

FIG. 11 illustrates a representative state based Finite State Machinedesign control circuit according to one embodiment of the invention;

FIG. 12 illustrates a representative transition based Finite StateMachine design control circuit according to one embodiment of theinvention;

FIG. 13 illustrates a representative data-path register design controlcircuit according to one embodiment of the invention;

FIG. 14 illustrates a representative part of the design control circuitaccording to one embodiment of the invention;

FIG. 15 is a block diagram of a portion of an instrumentation systemwhich includes a cross-reference analysis module and a cross-referencedatabase according to one embodiment of the invention;

FIG. 16 is a block diagram of a portion of an instrumentation systemwhich includes a DFT analysis module according to one embodiment of theinvention;

FIG. 17 is a data flow diagram illustrating DIC creation processingaccording to one embodiment of the invention;

FIG. 18 is a flow diagram of HDL-based hardware debugging processingaccording to one embodiment of the invention;

FIG. 19 is a data flow diagram of a debugging process performed by aHDL-based hardware debugger according to one embodiment of theinvention;

FIG. 20 is a block diagram of a hardware/software co-debugging systemaccording to one embodiment of the invention; and

FIG. 21 is a block diagram of a hardware/software co-debugging systemaccording to one embodiment of the invention.

DETAILED DESCRIPTION OF THE INVENTION

The present invention relates to techniques and systems for debugging anelectronic system having instrumentation circuitry included therein. Theinvention facilitates analysis, diagnosis and debugging fabricatedhardware designs at a Hardware Description Language (HDL) level.Although the hardware designs (which were designed in HDL) have beenfabricated in integrated circuit products with limited input/outputpins, the invention enables the hardware designs within the integratedcircuit products to be comprehensively analyzed, diagnosed, and debuggedat the HDL level at speed. The ability to debug hardware designs at theHDL level facilitates correction or adjustment of the HDL description ofthe hardware designs.

The following discussions will be made clearer by a brief review of therelevant terminology as it is typically (but not exclusively) used.Accordingly, to assist readers in understanding the terminology usedherein, the following definitions are provided.

“Software” is defined as but not limited to programming language contentwritten using a programming language. Examples of programming languagesinclude C, C++, Basic, assembly, and Java.

“HDL” is a Hardware Description Language. A hardware descriptionlanguage is defined as any programming language that can describe thehardware portion of an electronic system. Examples of HDLs include VHDLwhich is described in the IEEE Standard VHDL Language Reference Manualavailable from the Institute of Electrical and Electronic Engineers inPiscataway, N.J., which is hereby incorporated by reference; Verilog HDLwhich is described in Hardware Modeling with Verilog HDL by EliezerSternheim, Rajvir Singh, and Yatin Trivedi, published by AutomataPublishing Company, Palo Alto, Calif., 1990, which is herebyincorporated by reference; and SystemC which stems from the Open SystemCInitiative (OSCI) originally started by Synopsys, Inc. of Mountain View,Calif. General purpose programming languages such as C++, C, andassembly languages may also be used as a HDL.

A “high level HDL description” is a HDL description in which at least aportion of the description is at register transfer level (RTL) orhigher. For VHDL this synthesizable, register transfer level subset isdescribed in the IEEE 1076.6-1999 Standard for VHDL Register TransferLevel (RTL) Synthesis, available from the Institute of Electrical andElectronic Engineers in Piscataway, N.J., which is hereby incorporatedby reference. The synthesizable register transfer level subset of theVerilog HDL is described in “Verilog HDL: A Guide to Digital Design andSynthesis” by Samir Palnitkar, SunSoft Press, 1996.

A “RAM” is a Random Access Memory—defined as an electronic componentcapable of storing data.

“ASIC” is an Application Specific Integrated Circuit. An ASIC device isan electronic component of a system. ASICs are custom devices createdfor a specific purpose within the electronic system. ASIC devices areeasier and faster to create with respect to a full custom semiconductordevice. An ASIC may be described using HDL and implemented usingsynthesis.

An “FPGA” is a Field Programmable Gate Array. FPGAs are electroniccomponents that have a configurable function. These devices are able tochange their functionality via an information stream transferred to thedevice. These electronic components are available from a number ofdifferent suppliers in a wide range of sizes and speeds. One example ofthese devices are the Virtex FPGA devices from Xilinx, Inc. located inSan Jose, Calif. An FPGA design may be described using HDL andimplemented using synthesis.

A “Central Processing Unit” or “CPU” is circuitry controlling theinterpretation and execution of software programmed instructions,performs arithmetic and logical operations on data, and controlsinput/output functions. For the following descriptions the term CPU willbe used to also denote other processing elements such asmicroprocessors, digital signal processors, microcontrollers, etc.

A “register” is an element in digital circuitry which can store one ormore bits. Examples for registers are the various types of flip-flopsand latches.

A “PLD” is an Programmable Logic Device. PLDs are electronic componentsthat have a configurable function. These devices are able to changetheir functionality via an information stream transferred to the device.These electronic components are available from a number of differentsuppliers in a wide range of sizes and speeds. One example of thesedevices are the Apex PLD devices from Altera Corporation in San Jose,Calif. A PLD design may be described using HDL and implemented usingsynthesis.

“Electronic Components” are defined as but not limited to, transistors,logic gates, integrated circuits, semi-custom integrated circuits, fullcustom integrated circuits, application specific integrated circuits(ASICs), gate arrays, programmable logic devices (PLDs), fieldprogrammable gate arrays (FPGAs), CPUs, Random Access Memory (RAM),mixed signal integrated circuits, systems on a chip (SOC), and systemson a printed circuit board.

An “Electronic System” is defined as a system that contains one or moredigital and/or analog Electronic Components connected together toperform specific operations or functions. An Electronic System can beimplemented entirely of hardware (Electronic Components) or consist of amix of hardware and software (programming language content).

“Mixed-signal designs” are defined as Electronic System designs whichincorporate both digital and analog signals.

The “HDL Design” is referred to as the portion of the electronic systemwhich is described in HDL and implemented in hardware. It is alsoreferred to as the “Design under Test” (DUT).

An “SOC” is a System On Chip. A SOC is defined as a device large enoughto contain an entire electronic system implementation. SOC devices canintegrate a number of electronic devices into one device.

An “HDL description” is the textual description of an HDL Design.

“HDL source code” is referring to the text files which contain the HDLdescription.

An “HDL identifier” is an object in an HDL description which representsa signal, a set of signals, a storage element, or a set of storageelements and which can take a value from a set of possible values. EachHDL identifier is associated with a particular scope defined by thesyntax of the underlying hardware description language.

A “Technology Mapping Process” is defined as the process of transforminga particular representation of an electronic design into a designconsisting entirely of primitive electronic elements from a designlibrary for a target technology. The representation of said electronicdesign from which the Technology Mapping Process begins is dependent onthe particular Technology Mapping Process being employed. However, saidrepresentation usually consists of simple boolean elements. For example,said representation may consist entirely of an interconnected set of2-input/1-output logic elements with each said element performing theNAND function. An example of a tool that performs the Technology MappingProcess is Design Compiler from Synopsys in Mountain View, Calif.

“Synthesis” is defined as the process of creating an electronicimplementation from the functional description of a system. An exampleof a tool that performs this operation is Design Compiler from Synopsysin Mountain View, Calif. which reads electronic system descriptionswritten in a synthesizable subset of VHDL and Verilog and produces atechnology mapped design as an output.

“Behavioral HDL” is an HDL description at an algorithmic level ofabstraction in which neither the timing behavior nor the structure ofthe HDL Design is explicitly described.

“Behavioral synthesis” transforms a behavioral HDL description into aregister transfer level (RTL) description where the timing behavior andthe structure of the HDL Design is fixed. This RTL description is thenprocessed in synthesis and technology mapping. An example of a tool thatperforms behavioral synthesis is Behavioral Compiler from Synopsys, Inc.of Mountain View, Calif.

A “System Clock” is defined as a main timekeeping signal in a design.All operations that are relative to the System Clock will proceed whenthe System Clock becomes active.

“Constraints” are defined as limits placed on parameters for theimplementation of an electronic system. Parameters of an electronicsystem can include but are not limited to register to registerpropagation delay, system clock frequency, primitive element count, andpower consumption. These constraints can be used by synthesis tools toguide the implementation of the electronic design.

“Fabrication” is the process of transforming a synthesized andtechnology mapped design into one or more devices of the targettechnology. For example, the fabrication of ASICs involves manufacturingand the fabrication of FPGAs and PLDs involves device configuration.

“DFT” is Design-for-test. DFT is defined as a process in which anelectronic system designer will include structures in the electronicsystem that facilitates manufacturing testing.

“Design Rule Check” (DRC) are checks performed before integrated circuitmanufacturing to ensure that in the placed and routed technology mappeddesign none of the rules of the target technology process is violated.Examples for such DRC are checks for shorts, spacing violations, orother design-rule problems between logic cells. An example for a toolthat does DRC is Dracula from Cadence Design Systems, Inc. in San Jose,Calif.

“Functional Specification” is defined as the documentation thatdescribes the necessary features and operations of a system.

A “functional failure” is a behavior of a design which does not meet thefunctional specification which was used in the creation of the design.Every step in the design process can potentially cause a functionalfailure. Functional failures can be classified depending on which stepof the design process caused the functional failure.

A “fault” is a specific type of functional failure. This type of failureis due to one or more manufacturing defects causing a functional failurein the fabricated design.

A “design error” is a specific type of functional failure where the HDLdescription's behavior did not match the functional specification.

A “tool error” is a specific type of functional failure which wasintroduced by design tools because the HDL description was not properlyprocessed such that the functional specification is not met by theimplementation.

An “environment error” is a specific type of functional failure causedby a particular combination of environmental parameters such astemperature, humidity, pressure, etc.

A “Functional Simulator” is a tool that mimics the functional behaviorof a model of an electronic system which is described using HDL.

A “Testbench” is defined as an electronic system description thatpresents stimulus to and/or gathers information from the targetelectronic system design to be verified. In some cases the testbenchignores the response from the target electronic system design. Atestbench is used to mimic the behavior of the target environment inwhich the electronic system being developed will operate. A testbenchmay comprise both hardware and software.

A “Target Environment” is the system the electronic system is specifiedto interact with and/or to run in. A target environment may compriseboth hardware and software.

The “Target Speed” of an electronic system is the speed and/or the speedrange the electronic system is specified to run at. Examples formeasures for the target speed and the speed range are clock frequency,response time, time to propagate, and cycle time.

“Debugging” is the process of comparing the behavior of animplementation of the electronic system to the electronic systemfunctional specification. The purpose of debugging is to find causes andremedies for functional failures.

“Co-Debugging” or “hardware/software co-debugging” is defined as theprocess of debugging the software and hardware of an electronic systemconcurrently.

A “FSM” is Finite State Machine—defined as an electronic system controlstructure. The design and implementation of FSM is described in greatdetail in Synthesis and Optimization of Digital Circuits, by GiovanniDeMicheli, McGraw Hill, 1994.

A “HDL Building Block” is a functional unit of an HDL Design from whichthe HDL Design is constructed. A HDL Building Block (BB) performscalculations on the signals to which it is connected and communicateswith other BBs in the design. The communication is through connectinginternal signals of a BB to communication ports of the BB and/orconnecting internal signals of the BB to communication ports of otherBBs in the HDL Design. Examples of BBs are Entities in the VHDL languageand Modules in the Verilog language.

A “Hard Block” is an electronic system which has a pre-definedfunctionality and which can be incorporated into another electronicsystem. Commonly, the form of the Hard Block is such that thefunctionality of the Hard Block can not be altered. An example of a hardblock is an HDL Design which implements a industry standard buscontroller.

A “Design State” is defined as the logical values taken by the storageelements of the design at a particular time, combined with the logicalvalues taken by the inputs of the design taken at the same particulartime.

The “System State” or “State of the System” is a synonym for “DesignState.” “Real-time” means a task, process or response occurssubstantially immediately. The term is used to describe a number ofdifferent computer features. For example, real-time operating systemsare systems that respond to input immediately. Real-time is also usedfor describing tasks in which the computer must react to a steady flowof new information without interruption. Real-time can also refer toevents simulated by a computer at the same speed that they would occurin real life.

Embodiments of this aspect of the invention are discussed below withreference to FIGS. 1-21. However, those skilled in the art will readilyappreciate that the detailed description given herein with respect tothese figures is for explanatory purposes as the invention extendsbeyond these limited embodiments.

FIG. 1A is a block diagram of a hardware debugging system 100 accordingto one embodiment of the invention. The hardware debugging system 100operates to debug a hardware product referred to herein as a DeviceUnder Test (DUT) 102. The DUT 102 is typically part of a larger hardwareproduct referred to as an electronic system 104. The DUT 102 can pertainto a single integrated circuit chip, multiple integrated circuit chips,a system on a chip, or a system on a printed circuit board.

According to the invention, the DUT 102 includes Design InstrumentationCircuitry (DIC) 106. The DIC 106 is provided within the DUT 102 in orderto facilitate debugging of the DUT 102. The DIC 106 can be providedwithin the DUT 106 in either a centralized or distributed manner.

The hardware debugging system 100 operates to determine the DIC 106 thatis provided within the DUT 102. In this regard, an original HDLdescription 108 of the electronic system 104 is received at aninstrumentor 100. The instrumentor 100 modifies or alters the originalHDL description 108 to produce an instrumented HDL description 112. Theinstrumented HDL description 112 represents not only the electronicsystem 104 with the DUT 102 provided therein, but also the DIC 106 thatis provided within the DUT 102. The instrumentor 100 also stores DICinformation to a design instrumentation database 114. By storing the DICinformation in the design instrumentation database 114, thehardware-based debugging of the DUT 102 is facilitated.

The hardware debugging system 100 also includes synthesis and place &route systems 116. The synthesis and place & route systems 116 receivesthe instrumented HDL description 112 and performs conventional synthesisas well as place & route operations in order to produce an instrumenteddesign 118. Although not shown in FIG. 1A, other additional tools can beutilized to produce or enhance the instrumented design 118. Examples ofadditional tools include a Design-For-Test (DFT) tool or a Design RuleCheck (DRC) tool. The instrumented design 118 represents a description(e.g., design files) of the electronic system 104 that would bethereafter fabricated.

Hence, once the instrumented design 118 is available, fabrication 120can be performed. The fabrication 120 produces the electronic system 104having the DUT 102 with the DIC 106 provided therein. Fabrication is theprocess of transforming a synthesized and technology mapped design(e.g., the instrumented design 118) into one or more devices of thetarget technology. For example, if the target technology is ApplicationSpecific Integrated Circuits (ASICs) then the fabrication involvesmanufacturing, and if the target technology is Field Programmable GateArrays (FPGAs) or Programmable Logic Devices (PLDs) the fabricationinvolves device configuration.

At this point, the electronic system 104 is a hardware product that hasbeen produced. This hardware product can then be debugged using aHDL-based hardware debugger 122. More particularly, the HDL-basedhardware debugger 122 couples to the DIC 106 so that it is able tocommunicate with the DIC 106 when debugging the DUT 102. The HDL-basedhardware debugger 122 also couples to the design instrumentationdatabase 114 so that access to the DIC information is available. As aresult, the HDL-based hardware debugger 122 enables a user to debug theDUT 102 and/or hardware and/or software interacting with the DUT 102 inclose relation to the original HDL description 108. Further, in oneembodiment, debugging can be performed while the electronic system 104and the DUT 102 operate in the target environment, at target speed.

FIG. 11B is a block diagram of a hardware debugging system 150 accordingto another embodiment of the invention. The hardware debugging system150 is similar to the hardware debugging system 100 and includes many ofthe same components. Hence, the hardware debugging system 150 enables auser of the HDL-based hardware debugger 122 to debug the DUT 102 of theelectronic system 104 and/or hardware and/or software interacting withthe DUT 102, as noted above. However, the hardware debugging system 150includes a synthesis and place & route system 152 that includes aninstrumentor 154. Hence, the original HDL description 108 is supplied tothe synthesis and place & route system 152. The synthesis and place &route system 152 can then produce the instrumented design 118 whileusing not only synthesis and place & route tools but also theinstrumentor 154. In this embodiment, the instrumentor 154 is able to beembedded within synthesis and place & route system 152. Here, theinstrumentor 154 assists with producing the instrumented design 118which represents the electronic system 104 having the DIC 106 providedwithin the DUT 102. However, with the hardware debugging system 150, theoriginal HDL description 108 need not be modified to produce aninstrumented HDL description.

FIG. 2 is a flow diagram of basic instrumentation processing 200according to one embodiment of the invention. The basic instrumentationprocessing 200 is, for example, performed by the instrumentor 110illustrated in FIG. 1A or the instrumentor 154 illustrated in FIG. 1B.

The basic instrumentation processing 200 initially receives 202 a HDLdescription for an electronic system. The HDL description is thenanalyzed 203 to understand the characteristics of the electronic system.Next, parts (or portions) of the electronic system that are to beexamined and/or modified are determined 204. Typically, the parts of theelectronic system to be examined and/or modified (e.g., instrumented)are within a DUT such as the DUT 102 illustrated in FIGS. 1A and 1B.Hence, the parts of the electronic system to be examined and/or modifiedrepresent various signals and/or components within the DUT. After theparts of the electronic system to be examined and/or modified have beendetermined 204, design instrumentation circuitry (DIC) is generated 206.Preferably, the DIC is determined 204 based on the parts of theelectronic system to be examined and/or modified. In this regard, theDIC can be at least partially customized to the application such as theamount or degree of testing or debugging desired. Thereafter, the DIC isincorporated 208 into the electronic system. The DIC can be incorporated208 into the electronic system (namely, the DUT) in various ways. In oneembodiment, the DIC can be incorporated by adding HDL to the originalHDL for the electronic system. In another embodiment, the DIC can beincorporated by modifying a netlist description for the electronicsystem. Following the operation 208, the basic instrumentationprocessing 200 is complete and ends.

Design instrumentation (DI) is a process by which a HDL description ofan electronic system is analyzed, and then a DIC computed. The DIC isthereafter incorporated (e.g., added) into the electronic system tofacilitate debugging. The DIC can be added to the electronic system in avariety of ways. In one embodiment, DIC can be added to the electronicsystem by adding an HDL description of the DIC to the HDL description ofthe electronic system. In another embodiment, the DIC can be added tothe electronic system during synthesis. The DIC provides mechanisms tocontrol the examination and/or modification of a running electronicsystem. Thus, the DIC allows to analyze, diagnose, and/or debug the DUTby giving detailed and accurate information about its current state ofoperation, as well as the state history.

FIG. 3 is a block diagram of an instrumentation system 300 according toone embodiment of the invention. The instrumentation system 300 operatesto perform design instrumentation operations to produce an appropriateDIC.

The instrumentation system 300 includes an instrumentor 302. Theinstrumentor 302 operates to determine the appropriate DIC for theelectronic system (namely, the DUT) that is to be eventually hardwaredebugged. The instrumentor 302 receives an original HDL description 304as well as instrumentation directives 306. The instrumentationdirectives 306 are instructions to the instrumentor 302 that inform theinstrumentor 302 of the portions, parts or areas of the original HDLdescription 304 that are to be examined and/or modified. Theinstrumentation directives 306 can be predetermined or interactivelyprovided by a user through a user interface. Additionally, theinstrumentor 302 can further receive design constraints 308, Design ForTest (DFT) information 310, instrumented pre-designed blocks 312 and DICtemplate(s) 314.

The design constraints 308 are constraints on the particular designassociated with the original HDL description 304. More particularly,design constraints are limits placed on parameters for an implementationof an electronic system. Some examples of the parameters that can belimited by design constraints include register-to-register propagationdelay, system clock frequency, primitive element count, and powerconsumption. The constraints on the parameters are used by synthesis andplace & route tools to guide the implementation of the electronicdesign.

The DFT information 310 is information about features (e.g., structures)of the original HDL description 304 that pertain to testing. The DFTinformation is used to facilitate manufacturing testing. For example,the DFT information 310 can provide a description of a scan-chainprovided within the original HDL description 304. The instrumentor 302can utilize portions of the DFT information 310 to reduce the circuitryrequired for the DIC.

The DIC can make use of previously instrumented pre-designed blocks 312.In case the electronic system contains pre-designed blocks which havebeen instrumented, the DIC can communicate with the previouslyinstrumented pre-designed blocks 312 to facilitate their debugging. TheDIC template(s) 314 provide one or more templates for the instrumentor302 to utilize when producing the DIC.

The instrumentor 302 outputs an instrumented description 316. In oneembodiment, the instrumented description 316 can be represented as aninstrumented HDL description in which the original HDL description 304has been enhanced to include a HDL description of the DIC (see FIG. 1A).In another embodiment, the instrumented description 316 can represent aninstrumented netlist (see FIG. 1B). The instrumentor 302 also producesan optional DIC HDL description 318. The DIC HDL description 318 can beutilized by a functional simulator or synthesis and place & route tools.The instrumentor 302 can also produce an optional DIC simulation model322 that permits functional simulation of the instrumented description316. Still further, the instrumentor 302 can output synthesis and place& route constraints 324 and modified DFT information 326. The synthesisand place & route constraints 324 can be utilized by the synthesis andplace & route tools. The modified DFT information 326 can also be usedby the synthesis and place & route tools, so that the resultingelectronic system is able to be tested as originally designed.

The instrumentation system 300 also includes a design instrumentationdatabase 320 that stores instrumentation information. Theinstrumentation information includes information on the types ofinstrumentations that have been done, the DIC and other information asexplained in greater detail below. As noted above, an HDL-based hardwaredebugger (e.g., debugger 122) eventually utilizes the DIC informationstored in the design instrumentation database 320 when performinghardware debugging of the electronic system. Additional details on thedesign instrumentation database 320 are provided in FIG. 6 below.

FIGS. 4A and 4B are flow diagrams of detailed design instrumentationprocessing 400 according to one embodiment of the invention. Thedetailed design instrumentation processing 400 is, for example,performed by the instrumentor 110 illustrated in FIG. 1A, theinstrumentor 154 illustrated in FIG. 1B, or the instrumentor 302illustrated in FIG. 3.

The detailed design instrumentation processing 400 initially receives402 a HDL description of an electronic system. The HDL description isthen parsed and analyzed 404. The analysis 404 of the HDL descriptioncan identify portions that cannot be instrumented or that can only beinstrumented in certain ways. The result of the analysis 404 can be usedto determine whether particular instrumentation directives are valid,and thus can be followed by the instrumentor.

Additionally, one or more of design constraints, DFT information,predetermined instrumentation directives, or pre-designed blocks mayalso optionally be received 406. Then, instrumentation directives aredetermined 408. Here, instrumentation directives can be predeterminedand thus provided or can be determined through user interaction. FIGS.5A-5D, discussed below, pertain to user interaction to produceinstrumentation directives.

After the instrumentation directives are determined 408, a customizedDIC is produced 410 based on the HDL description and the instrumentationdirectives. Hence, the customized DIC is tailored to the particular HDLdescription and the particular instrumentation directives. By tailoringthe DIC to the particular HDL description and the particularinstrumentation directives, the customized DIC makes efficient use ofits circuitry. Since the DIC consumes area (e.g., die space) on thehardware product (e.g., semiconductor chip), making the customized DICefficient and compact is advantageous. In producing the customized DIC,the detailed design instrumentation processing 400 is able to reusepre-designed blocks that have already been instrumented. In other words,the customized DIC can communicate with existing DICs of pre-designedblocks that represent other portions of the electronic system (or evenexternal systems).

Additionally, the DIC can be optimized 412 to reduce hardware overheadand/or maximize coverage. Here, the optimization 412 to the DIC enablesthe hardware overhead associated with the DIC to be reduced which isadvantageous in producing or using integrated circuit products. Forexample, cost analysis can be performed during the optimization toexplore the different structures in the context of a givenimplementation technology and given design constraints. Variations ofthe DIC can thus be explored in order to minimize the overhead of theDIC on the hardware in terms of area, delay, power consumption,routability, and/or testability. Variations of the DIC can be describedvia DIC templates. The optimization 412 can also try to increase theeffects of the instrumentation with regards to the hardware overhead.For example, if some certain signals can be examined, some other signalsmay also be able to be examined without any or minimal hardwareoverhead.

Next, a decision 414 determines whether design constraints have beenprovided. Typically, the design constraints are provided in a file whichcontains specifications for area, delay, power consumption, routabilityand testability. When the decision 414 determines that designconstraints have been provided, then the DIC may be modified 416 in viewof the design constraints: Also, modifications to the design constraintsmay be performed so that the overall design of the electronic system(including the DIC) complies with the intent of the original designconstraints. For example, timing constraints may be changed to reflectthe insertion of the DIC. In addition, additional design constraintsmight be generated, which, for example, may be used to guide synthesisand place & route tools in optimizing the DIC.

Following operation 416, as well as following the decision 414 whendesign constraints are not provided, a decision 418 determines whetherDFT information has been provided. When the decision 418 determines thatDFT information has been provided, then the DFT information is compliedwith or reused 420. When complied with, the detailed designinstrumentation processing 400 renders the customized DIC compatible orcompliant with the DFT information (e.g., existing DFT structures in thedesign). For example, scan-chains or boundary-scans can be provided ormodified to take into account the DIC. Alternatively, when the DFTinformation is reused, the customized DIC can make use of portions ofthe circuitry made available through the DFT information and therebymake use of existing circuitry. The modifications to the DFT informationcan reflect the ability of the DIC to utilize portions of the circuitrywithin the electronic system associated with the DFT information as wellas with the ability to modify the DFT information to preserve the intentof the designer after the DIC is included within the electronic system.

Following the operation 420, as well as following the decision 418 whenthe DFT information is not provided, a decision 422 determines whetherinstrumented, pre-designed blocks have been provided. When the decision422 determines that instrumented, pre-determined blocks have beenprovided, then the DIC of each instrumented, pre-designed block isconnected 424 to the current DIC. This facilitates debugging of theelectronic system which contains pre-designed blocks.

Following operation 424, as well as following the decision 422 wheninstrumented, pre-designed blocks are not provided, DIC information isstored 426 to a design instrumentation database. The DIC informationincludes a description of the DIC, the instrumentation directives, andDIC connectivity information. The DIC information can also includecross-reference data that relates elements in the design of theelectronic system (i.e., hardware implementation) to and from the HDLdescription. Then, the customized DIC can then be added 428 to theelectronic system. The customized DIC can be added 428 to the electronicsystem in a variety of different ways. For example, with respect to anembodiment such as illustrated in FIG. 1A, the customized DIC can beadded 428 to the electronic system by producing the instrumented HDLdescription which describes the electronic system with the DIC includedtherein. Alternatively, with respect to an embodiment such asillustrated in FIG. 1B, the customized DIC can be added to theelectronic system by modifying a netlist that defines the electronicsystem.

Following operation 428 the detailed design instrumentation processing400 operates to produce and output 430 the instrumented description, anoptional DIC simulation model and an optional DIC HDL description. TheDIC simulation model can be used by a simulator when functionallysimulating the operation of the DUT. The DIC HDL description may forexample also be used for simulation. Following the operation 430, thedetailed design instrumentation processing 400 is complete and ends.

As noted above, the instrumentation directives can be predetermined andthus provided or can be determined through user interaction. When theinstrumentation directives are predetermined, they can be obtained froma design instrumentation file. In one embodiment, the instrumentationdirectives specify design visibility, design patching and design controlcriteria for particular portions of the design for the electronicsystem.

Design Visibility (DV) is monitoring the entire or partial state of theDUT at, and relative to, predetermined events. An important aspect of DVis relating the states of operation back to identifiers in the originalHDL description for examination during HDL-based hardware debugging. Inone embodiment, DV is done by sampling the values of one or more signalsof the DUT for a particular time interval determined by one or morepredetermined events. The events are determined by Design Control whichis described below. Design Visibility serves to monitor the state ofoperation of the DUT, but does not alter the DUT's behavior in any way.However, in some situations, it is advantageous to have a method toalter the behavior of the DUT after the hardware has been fabricated.Design Patching (DP) is to alter the behavior of the DUT to apredetermined particular desired state at predetermined events. Theevents are determined by Design Control which is described below. Aparticular desired state of a DUT is a particular setting of the valuesof all or a subset of all storage components in the DUT.

Design Control (DC) provides the designer with a method to specify theevents that control DV and DP. DC can be accomplished by one or moretrigger conditions. A trigger condition is a conditional expressioncomprising HDL identifiers where the conditional expression denotes acombination comprising a particular state and/or state transition,and/or history of states and/or history of state transitions, the DUT,or a portion of it, can be in. Each time a particular trigger conditionis met an associated trigger event is produced. One or more triggerevents can be combined to issue a particular predetermined triggeraction which may control the DV and DP and may control other functionsrelated to HDL-based hardware debugging. A unique combination comprisingone or more units of DV and/or DP all controlled by the same triggeraction forms a trigger action group.

A watch-point is a special case of a trigger condition which isexplicitly defined using a predetermined conditional expression of HDLidentifiers. A watch-point has no direct relationship with the HDLdescription other than its expression is made up with identifiers of theHDL description.

A break-point is a special case of a trigger condition, where thetrigger condition is implicitly specified by selecting a particularsource code location in the HDL description. A source code location is aunique combination comprising a file name, a line number and a columnposition within a textual HDL description.

An error trap is a special case of a watch-point where the triggercondition describes an erroneous or undesired state of the hardware. Aproperty check is a special case of an error trap where the triggercondition is explicitly specified by a particular property of a portionof the hardware. In the event such property is not fulfilled the triggercondition is met. Properties to be checked can either be implicitlyderived from the functionality of the hardware or explicitly given bythe designer of the electronic system.

FIG. 5A is a flow diagram of selection processing 500 according to oneembodiment of the invention. The selection processing 500 pertains touser interaction with the HDL description to produce instrumentationdirectives. The selection processing 500 is, for example, performed byoperation 406 illustrated in FIG. 4A when determining instrumentationdirectives.

The selection processing 500 initially displays 502 a HDL description.The HDL description pertains to the electronic system. At this point, auser can interact with a graphical user interface to make a specificinstrumentation directive with respect to the HDL description beingdisplayed. Optionally, to guide a user in his selections, the results ofan analysis of the original HDL description can be displayed as well(e.g., operation 404, FIG. 4A). Examples of the particular types ofinstrumentation directives include a selection of a trigger condition, asampling signal or a patching signal. Hence, a decision 504 determineswhether a trigger condition selection has been made. When the decision504 determines that a trigger condition selection has been made, thentrigger condition selection processing 506 is performed. Alternatively,when the decision 504 determines that a trigger condition selection hasnot been made, then a decision 508 determines whether a sampling signalselection has been made. When the decision 508 determines that asampling signal selection has been made, then sampling signal selectionprocessing 510 is performed. On the other hand, when the decision 508determines that a sampling signal selection has not been made, then adecision 512 determines whether a patching signal selection has beenmade. When the decision 512 determines that a patching signal selectionhas been made, then patching signal selection processing 514 isperformed. Following any of operations 506, 510 and 514, as well asfollowing the decision 512 when a patching signal selection has not beenmade, instrumentation optimization can be performed 516. Theinstrumentation optimization operates to consolidate the variousselections so that the DIC required to implement the various triggerconditions, sampling signals and patching signals can be efficientlyimplemented. Following the operation 516, a decision 518 determineswhether more selections are to be made by the user. When the decision518 determines that more selections are to be made, then the selectionprocessing 500 returns to repeat the decision 504 and subsequentoperations. Alternatively, once the decision 518 determines that no moreselections are to be made, the selection processing 500 is complete andends.

The trigger condition selection processing 506 illustrated in FIG. 5Acan be utilized to select or establish implicit trigger conditions orexplicit trigger conditions. An example of an implicit trigger conditionis a break-point, and an example of an explicit trigger condition is awatch-point, or an error trap, or a property check.

FIG. 5B is a flow diagram of break-point processing 520 according to oneembodiment of the invention. The break-point processing 520 representsan embodiment of the trigger condition selection processing 506 in thecase in which an implicit trigger condition (namely, a break-point) isinvolved.

The break-point processing 520 initially identifies 522 feasiblebreak-point conditions and types. Typically, such information isobtained analyzing the original HDL description (e.g., operation 404,FIG. 4A). Next, the feasible break-point conditions and types aredisplayed 524. Here, the feasible break-point conditions and types canbe displayed to a user by a user interface. At this point, a user isable to select a location within the HDL description of the electronicsystem where a break-point is to be set. In one embodiment, a userinterface assists the user in making such a location selection withrespect to the HDL description (i.e., HDL location). A decision 526determines whether a HDL location has been selected. When the decision526 determines that a HDL location selection has not yet been made, thenthe decision 526 causes the break-point processing 520 to await such aselection. Once the decision 526 determines that a HDL location has beenselected, then a decision 528 determines whether the selected HDLlocation is permitted. In other words, the decision 528 determineswhether it is valid to instrument the location within the HDLdescription of the electronic system with a break-point. When thedecision 528 determines that the selected HDL location is not permitted,then an error message is displayed 530. On the other hand, when thedecision 528 determines that the selected HDL location is permitted,then the status type of the selected break-point is updated 532. Next,break-point information is entered 534 into the trigger conditiondatabase for later processing. The break-point information comprises theHDL location of the selected break-point, and the current status type.According to one embodiment, the status type for a selected break-pointis “selected”.

FIG. 5C is a flow diagram of explicit trigger condition selectionprocessing 540 according to one embodiment of the invention. As notedpreviously, one example of an explicit trigger condition is awatch-point. The explicit trigger condition selection processing 540begins with a decision 542 that determines whether a trigger conditionexpression has been received. In one embodiment, a user interfaceassists the user in providing such information. The trigger conditionexpression defines the explicit trigger condition being set. When thetrigger condition expression has not yet been received, the decision 542causes the explicit trigger condition processing 540 to await receipt ofsuch information (selections). When the decision 542 determines that atrigger condition expression has been received, the status type of theselected trigger condition is updated 544. For example, the status typefor the selected (explicit) trigger condition is “selected”. Thentrigger condition information is entered 546 into the trigger conditiondatabase. The trigger condition information includes the triggercondition expression, the HDL identifiers involved in building thetrigger condition expression, and a status type.

Although the break-point processing 520 and the explicit triggercondition processing 540 illustrated in FIGS. 5B and 5C pertain toselection and/or entry of trigger conditions, it should be noted thatselections can also be made to de-select previously selected triggerconditions. Such processing is generally similar to the selectionprocessing, with the major exception being that the status type of theselected trigger condition is updated to “non_selected”, meaning that noinstrumentation shall be performed regarding to that portion of the HDLdescription.

FIG. 5D is a flow diagram of sampling signal selection processing 560according to one embodiment of the invention. The sampling signalselection processing 560 is, for example, one representativeimplementation of the sampling signal selection processing 510illustrated in FIG. 5A.

The sampling signal selection processing 560 begins with a decision 562that determines whether a signal selection has been received. Here, auser is able to select signals by selection of an HDL identifier withinthe HDL description of the electronic system. In one embodiment, a userinterface assists the user in making such a selection with respect tothe HDL description. Hence, the decision 562 determines whether such asignal selection has occurred. When the decision 562 determines that asignal selection has not yet occurred, the sampling signal selectionprocessing 560 awaits such a selection. Once the decision 562 determinesthat a signal selection has been received, then a decision 564determines whether the selected signal is to be associated with anexisting trigger action group of a prior signal selection or whether itbecomes a member of a new trigger action group. When decision 564determines that the signal selection is to be associated with anexisting trigger action group, a decision 566 determines whether theuser has selected an existing trigger action group. In one embodiment, auser interface assists the user in making such a selection. When thedecision 566 determines that a trigger action group selection has notyet been received, the sampling signal selection processing 560 awaitssuch a selection. Once the decision 566 determines that a trigger actiongroup has been selected, the selected signal is associated 568 with theselected trigger action group. On the other hand, when the decision 564determines that the selected signal shall become a member of a newtrigger action group, a new trigger action group is created 570 and theselected signal is associated 568 with that new trigger action group.Following operation 568, the status type of the selected signal isupdated 572. The status type for a selected signal is updated 572 to“selected”, meaning that the selected signal is selected forinstrumentation. Following operation 572 the selected signal is entered570 into a signal database (see FIG. 6). Following the operation 570,the sampling signal selection processing 560 is complete and ends.

Patching signal selection processing can also be performed in a similarmanner as the sampling signal selection processing 560 illustrated inFIG. 5D. In other words, the patching signal selection processing 514illustrated in FIG. 5A can also be represented by the processing 560illustrated in FIG. 5D. Besides selection of sampling or patchingsignals in accordance with the processing illustrated in FIG. 5D,similar processing can also be performed to de-select sampling orpatching signals, with the major exception that the status type of theselected signal would be updated to “non_selected”, meaning that noinstrumentation shall be performed regarding that particular signal.

Design instrumentation databases can be structured in a variety of ways.FIG. 6 is a diagram of a design instrumentation database 600 accordingto one embodiment of the invention. The design instrumentation database600 is, for example, suitable for use as the design instrumentationdatabase 114 illustrated in FIGS. 1A and 1B or the designinstrumentation database 320 illustrated in FIG. 3.

The design instrumentation database 600 includes a break-point database602 that stores break-points. The design instrumentation database 600also includes a signal value database 604 that stores signals within theelectronic system that are to be sampled or patched. Hence, thebreak-points and the signal values, respectively stored in thebreak-point database 602 and the signal value database 604, representinstrumentation directives (e.g., design visibility, design patchingand/or design control criteria) that govern the characteristics of theresulting DIC and its capabilities. Additionally, the designinstrumentation database 600 includes a DIC database 606, across-reference database 612, and a Register-to-Physical (R2P) database614. A representation of the resulting DIC that is produced by theinstrumentor is stored in the DIC database 606. The cross-referencedatabase 612 stores the associations of HDL identifiers (variables)within the HDL description to broaden the design visibility. The R2Pdatabase 614 stores translations from registers to physical addresses.The registers are, for example, registers of the DIC used to configurethe DIC and hold the status of the DIC and the DUT during hardwaredebugging. Physical addresses are given for each register to access thatregister in its implementation inside the DIC. Further, the designinstrumentation database 600 includes a text-to-netlist (T2N) database608 and a netlist-to-text (N2T) database 610. The T2N database 608 andthe N2T database 610 provide for each HDL identifier the associationsbetween the HDL location and elements within the netlist (internalrepresentation of the electronic system).

FIG. 7A is a block diagram of an instrumentation system 700 according toone embodiment of the invention. The instrumentation system 700represents a more detailed block diagram of an instrumentor togetherwith a design instrumentation database. For example, the instrumentationsystem 700 can be a more detailed embodiment of the instrumentationsystem 300 illustrated in FIG. 3.

The instrumentation system 700 receives a HDL description 702 of anelectronic system. A Design Instrumentation (DI) graphical userinterface 704 can display the HDL description on a display device. Auser can interact with the graphical user interface 704 to make or enterinstrumentation directives. A front-end module 706 receives the HDLdescription 702 and parses the HDL description 702 to form a parse-treestructure. The resulting parse-tree structure is stored in a parse-treedatabase 708. A code generation module 710 reads the parse-treestructure from the parse-tree database 708 and produces a hierarchicaldesign representation associated with the electronic system. Thehierarchical design representation provides a description of the designsbehavior and structure, such as a hierarchical netlist. The hierarchicaldesign representation is stored in a hierarchical design database 712. ADI optimization module 714 interacts with the information stored in thehierarchical design database 712. The information stored in thehierarchical design database 712 is also supplied to an analysis module716. The analysis module 716 interacts with the parse-tree database 708as well as the hierarchical design database 712 to analyze the HDLdescription of the electronic system design. The analysis includescontrol flow analysis which determines the feasible break-points whichare stored in a trigger condition database 718. Control flow analysis isfurther described in “High-Level Synthesis” by Daniel D. Gajski et al.,Kluwer Academic Publishers, 1992, which is hereby incorporated byreference. For each location in the HDL description which correlates toa control flow branch condition node, a unique combination of the HDLlocation and the trigger condition given by the control flow conditioncan be added as a feasible break-point into the trigger conditiondatabase 718. The purpose of control flow analysis is to reflect thatbreak-points can be set at very particular locations in the HDLdescription which pertain to HDL control flow statements.

The instrumentation system 700 also includes a location module 724 thatinteracts with the parse-tree database 708 and the hierarchical designdatabase 712 to produce source code location information represented asT2N information for a T2N database 726 and N2T information for a N2Tdatabase 728. The T2N information provides a method to obtain allelements in the parse-tree database 708 or the hierarchical designdatabase 712 which refer to an identifier at a given location in the HDLdescription. The N2T information provides a method to relate a givenelement of the parse-tree database 708 or the hierarchical designdatabase 712 to the originating location in the HDL description. Alocation query manager 730 interacts with the T2N database 726 and theN2T database 728 to allow a DI manager 732 to relate a location withinthe HDL description 702 to an element within a netlist (i.e., theparse-tree and/or the hierarchical design representation) and vice versaThe DI manager 732 receives the instrumentation directives, processesthem and adds them to the appropriate database (i.e., the triggercondition database 718 or the signal database 722). Instrumentationdirectives can be given using file-based DI criteria 734, interactivelyby the graphical user interface 704, or via pragmas in the HDLdescription. The use of instrumentation directives is explained ingreater detail below. The DI manager 732 then interacts with the triggercondition database 718, the signal database 722, the location querymanager 730, and the DI optimization module 714 to check eachinstrumentation directive for its validity. The information regardingthe validity is available in the trigger condition database 718 and thesignal database 722.

The DI optimization module 714 receives trigger conditions from thetrigger condition database 718 and also receives a DIC template from aDIC template database 720. Still further, the DI optimization module 714interacts with a signal database 722 to receive signals that are to beexamined and/or modified. The DI optimization module 714 performsvarious optimizations regarding the instrumentation directives to reducethe hardware overhead and/or broaden the instrumentation coverage.Additional details on DI optimization are provided below.

For the above-mentioned location determinations with respect toselections, the DI manager 732 queries the location query manager 730 torefer to identifiers in the HDL description 702, elements in theparse-tree database 708, and elements in the hierarchical designdatabase 712.

Selection status types are used to hold the selection information (i.e.,the instrumentation directives) and exchange the selection informationbetween the DI user interface 704, the DI manager 732 and the DIoptimization module 714. The selection status types used for theselection of implicit trigger conditions, explicit trigger conditions,sampling selections and patching selections can comprise: feasible,selected, implied, and not-selected.

The instrumentation directives can be provided in at least three ways,namely, user-based (interactive), file-based, and via pragmas in the HDLdescription. The user-based approach has been described above. Ingeneral, a user (e.g., an electronic system designer) makes designvisibility, design patching, and design control selections. Moreparticularly, the designer can select in the HDL description whichbreak-points, watch-points, error-traps, and property checks will beavailable for activation during HDL-based hardware debugging. Theseselections are stored in the trigger condition database 718. Thedesigner also selects in the HDL description which signals shall beavailable for examination during HDL-based hardware debugging. Theseselections are stored in the signal database 722. The designer selectsin the HDL description which signals shall be available for patchingduring HDL-based hardware debugging. These selections are stored in thesignal database 722.

When instrumentation directives are provided in a file, the file-basedDI criteria 734 is a human and/or computer readable rule set whichdescribes which signals shall be made visible, which signals shall bemade patchable, which break-points are enabled, and which triggerconditions shall be made detectable. The directives in the file-based DIcriteria 734 may be expressed in any of the HDL languages that thesystem accepts as input or may be expressed in a specifically designedlanguage. The directive to select an explicit trigger condition can, forexample, comprise a keyword to denote that the selection is a triggercondition, and a conditional expression of HDL identifiers which must bemet to issue a trigger event. Implicit trigger conditions, such asbreak-points, can, for example, be specified by a source code locationin the HDL description. The directive to select a signal for samplingcan, for example, comprise a keyword to denote that the selection is fora to-be-sampled signal, the unique HDL identifier of the selectedsignal, and an associated trigger action group. The directive to selecta signal for patching can, for example, comprise a keyword to denotethat the selection is for a to-be-patched signal, the unique HDLidentifier of the selected signal, and an associated trigger actiongroup. The file-based DI criteria 734 can be directly read by the DImanager 732 which stores selections of trigger conditions into thetrigger condition database 718 and stores selections of signal values tobe made visible and/or patchable into the signal database 722.

As noted above, the instrumentation directives can be provided viapragmas in the HDL description of an electronic system. Pragmas are HDLcode fragments which are inserted into the HDL description to definedesign visibility, design patching and design control. These pragmas areadded to the HDL description such that the behavior of the design of theelectronic system is not altered. One implementation adds pragmas to aHDL description as specially-marked HDL comments. By placing the pragmasin comments, other tools which read the HDL description containing thepragmas will be unaffected. However, the front-end module 706 canrecognize and interpret these pragmas inside the comments. Moreparticularly, providing instrumentation directives via pragmas can beaccomplished by the front-end module 706 recognizing the pragmasenclosed within comments and placing the appropriate information intothe parse-tree database 708. This information is read by the DI manager732 which stores the necessary information in the trigger conditiondatabase 718 and the signal database 722.

Several examples of pragmas are provided below. These pragmas arewritten in the form of a HDL comment with an indicator (e.g., “B2SI”) todifferentiate them from other comments. In the following examples,following the identifier “B2SI”, the remainder of the pragma describeseither a design control, or a design visibility, or a design patchingdirective. The exact form of the pragmas depend on the HDL languagebeing used. The following are examples of pragmas written in VerilogHDL.

The following example shows a comment including a pragma for designcontrol.

always @( a or b or c or d or e or f ) begin if( cond == 4 ′b1111 )begin // B2SI trigger(“trigger_name”, (a == 2 ′b10) && (d * e < f + 5′b1100)); end endThis pragma produces a trigger condition that is active if theexpression(a==2′b10) && (d*e<f+5′b1100)evaluates to true. The expression has the same meaning and variablescoping as it would were it a regular HDL expression. This trigger canalso be placed in the control flow of the design so the trigger will notbe active unless the control flow is active. In this example,(cond==4′b1111) must also be met to issue a trigger event. The triggercondition has a name (“trigger_name”) so that other pragmas may refer tothis trigger condition.

The following example shows a comment including a pragma for signalvisibility.

module mod1( in1, in2, in3, out ); input in1, in2; input in3; // B2SIvisible output out; . . .Here, the visibility pragma is being used to mark “in3” as visible.

The following example shows a comment including a pragma for signalpatching.

module mod2( in1, in2, in3, out ); input in1, in2; input in3; outputout; reg [1:0] aa; // B2SI patchable

Here, the patching pragma is being used to mark “aa” as patchable. Thetrigger condition for the sampling and/or patching can be specified byassociating it with a trigger action group (by referring to a triggername, for example “trigger_name”), or during HDL-based hardwaredebugging.

The optimization of the design instrumentation can enhance its effectsand can reduce hardware costs of the DIC. One example of an optimizationfor enhancing the effects of the instrumentation is implicationanalysis. One example for an optimization which aims to reduce thehardware costs of the DIC is resource sharing.

The selections of various trigger conditions and signals for samplingand/or patching may potentially imply other signal selections based ontheir controlability and observability dependencies. Controlability andobservability are, for example, commonly used-concepts in Automatic TestPattern generation of combinational and sequential logic. See D.Bhattacharya and J. P. Hayes, “Hierarchical Modeling for VLSI CircuitTesting,” Boston: Kluwer, 1990, p. 159, which is hereby incorporated byreference. Implication analysis works as follows. Initially, thehierarchical design database 712 and the DI optimimization module 714are consulted to determine whether a trigger condition with the statustype ““selected” implies certain other trigger conditions. If so, theimplied trigger conditions can also be detected during HDL-basedhardware debugging, have their status type set to “implied”, and bestored into the trigger condition database 718. Secondly, thehierarchical design database 712 and the DI optimization module 714 canbe consulted to determine whether certain other signal values areimplied by the selected signals. In particular, the implied signals canbe derived from the selected signals plus some calculations duringHDL-based hardware debugging. Each implied signal is then stored withits status type set to “implied” into the signal database 722.

Resource sharing is a widely used optimization which is, for example,used in synthesis. Although resource sharing can be performed using manydifferent approaches, in one approach to resource sharing, the DIoptimization module 714 operates to share resources in the DIC asfollows. First, by consulting the DIC template database 720, the DIoptimization module 714 knows about the structure and the cost model ofthe DIC and can determine whether trigger conditions and signals to besampled have commonalities which can be utilized for resource sharing.Second, the hierarchical design database 712 and the DIC templatedatabase 720 can be consulted by the DI optimization module 714 whendetermining whether other signals should instead be sampled, since suchsignals imply all the selected signals, but their sampling requires lesshardware overhead or leads to additional signal visibility. Third, byconsulting the DIC template database 720, the DI optimization module 714knows about the structure and the cost model of the DIC and candetermine whether trigger conditions and signals to be sampled havecommonalities which can be utilized for resource sharing. Fourth, byconsulting the DIC template database 720, the DI optimization module 714knows about the structure and the cost model of the DIC and candetermine whether signals to be patched have commonalities which can beutilized for resource sharing.

Once the trigger conditions and the signals to be sampled and/or patchedare determined, other portions of the HDL design can be integrated evenif such portions are not described by a synthesizable HDL descriptionbut are available as synthesized and physically realized hard blocks,such as previously designed hard blocks. If the hard blocks aresynthesized from instrumented HDL and include DIC, regardless whetherthe DIC is a complete or a partial, the previously inserted DIC can bere-used for debugging the hard blocks. The distinction between partialversus complete DIC is described in greater detail below.

In order for a hard block to be re-used, it should have associated DIdata stored in an associated design instrumentation database. FIG. 7B isa diagram of a hard block resolution system 750 according to oneembodiment of the invention. The data needed are a hard block's DICdatabase 752, a hard block's trigger condition database 754, a hardblock's signal database 756, and optionally HDL description 758. Often,vendors of hard blocks do not want to expose the internal workings oftheir design by showing its HDL description (e.g., source code). Toaccommodate this need, the HDL description is not required to describethe entire hard block's functionality. Some minimal HDL descriptionproviding just enough text to examine signals, to set watch-pointexpressions for the signals, and to set break-points at HDL locationswhich refer to implemented trigger detection circuitry is enough toenable HDL-based hardware debugging of the hard blocks. For example, ahard block implementing a simple controller might expose the controllerstate variable for sampling and for triggering on its value. It mightalso allow a user to set a break-point when the machine makes certaintransitions or receives certain signals from the circuitry to which itis connected. A hierarchy and hard block resolver 760 processes theinformation from the hard block's DIC database 752, the hard block'strigger condition database 754, the hard block's signal database 756 andthe optional HDL description 758, and merges same into the current HDLdesign's DIC database 736, the trigger condition database 718, thesignal database 722, and the original HDL description 702. As a result,the resolved information will be available during HDL-based hardwaredebugging.

The instrumentor 700 can also perform cross-reference analysis to gatherand store data in the design instrumentation phase such that theHDL-based hardware debugger will be capable of examining signals in theHDL description. Additionally, if the design instrumentationoptimization determines that other signals could be derived from thesampled signals, the HDL-based hardware debugger needs the HDLexpressions to compute the derived signals “on the fly” from the sampledsignals. The expressions are calculated during cross-reference analysisand stored in the cross-reference database 1504.

FIG. 15 is a block diagram of a portion of an instrumentation system1500 which includes a cross-reference analysis module 1502 and across-reference database 1504 according to one embodiment of theinvention. The cross-reference analysis module 1502 can be providedwithin the instrumentation system 700, and the cross-reference database1504 can be provided within the design instrumentation database 612 andutilized by the instrumentation system 700. The cross-reference analysismodule 1502 can couple to the location query manager 730, thehierarchical design database 712 and the signal database 722. Thecross-reference analysis module 1502 reads signal information from thesignal database 722. Each entry in the signal database 722 correspondsto one signal that is either selected or implied to be made visible.Each entry in the signal database 722 also comprises information onwhether the signal is to be sampled and/or patched in the DIC or whetherthe signal is derived from other to-be-sampled signals. In oneembodiment, for each signal that is derived from other to-be-sampledsignals, the following operations are performed. First, thecross-reference analysis module 1502 queries the HDL locationinformation of the signal from the location query manager 730. Thecross-reference analysis module 1502 looks up the signal in thehierarchical design database 712 and determines the proper HDLexpression to compute the derived signal from the set of sampledsignals. The cross-reference analysis module 1502 then writes the HDLexpression into the cross-reference database 1504.

The instrumentor 700 can also perform Design-for-Test (DFT) analysis. Ifthe electronic system contains additional circuitry for testability suchas scan-chains, boundary scan logic, JTAG tap-controllers or similar DFTfeatures, and if such circuitry is described in the DFT information(file) 310, then the circuitry can be shared to reduce the hardwareoverhead of the DIC. Example formats of such a DFT information file isthe Boundary-Scan Description Language (BSDL) or Hierarchical ScanDescription Language (HSDL), both defined by the IEEE 1149.1 JTAGstandard available from the Institute of Electrical and ElectronicEngineers (IEEE) in Piscataway, N.J., which is hereby incorporated byreference.

FIG. 16 is a block diagram of a portion of an instrumentation system1600 which includes a DFT analysis module 1602 according to oneembodiment of the invention. The DFT analysis module 1602 receivesinformation about the DFT information 310, the current implementation ofthe DIC as stored in the DIC database 736 and the hierarchical designdatabase 712, and the register-to-physical (R2P) address translationinformation (e.g., table) provided in the R2P database 614. The resultproduced by the DFT analysis module 1602 is the modified DFT information326, namely, altered register-to-physical address translationinformation (e.g., table), which is needed by post-processing DFT tools.The R2P database 614 needs to be updated each time DIC registers havebeen moved to different physical locations.

FIG. 17 is a data flow diagram illustrating DIC creation processing 1700according to one embodiment of the invention. The DIC and theinstrumented design is created at the end of the design instrumentationprocess. The DIC is described by the DIC HDL description 318. Theinstrumented design is described by the instrumented HDL description316. Additionally, various components of the design instrumentationdatabase 600 are established, including the R2P database 614, the DICdatabase 736, the signal value database 604, and the break-pointdatabase 602. The DIC creation processing 1700 has a data flow describedas follows.

First, the trigger condition database 718 and the signal database 722(which can result from the DI manager 732) are processed by a triggercondition code generation module 1706 and a signal code generationmodule 1708, respectively.

Second, for each entry in the trigger condition database 718, thetrigger condition code generation module 1706 generates the structuresof the trigger detection circuitry for the DIC according to the DICtemplate database 720. Then, such structures are added to thehierarchical design database 712. In addition, proper DIC registerconfiguration rules can be added to a DI rule database 1710.

Third, for each signal designated as to-be-sampled in the signaldatabase 722, the signal code generation module 1708 creates circuitryto sample such signal according to the structure in the DIC templatedatabase 720, and adds the structures to the hierarchical designdatabase 712 and the proper DIC register configuration rules to the DIrules database 1710.

Fourth, for each signal designated as to-be-patched in the signaldatabase 722, the signal code generation module 1708 generates thecircuitry to patch such signal according to the structure in the DICtemplate database 720, and adds such structures to the hierarchicaldesign database 712 and the proper DIC register configuration rules tothe DI rule database 1710.

Fifth, a break-point analysis module 1712 then reads the triggerdetection circuitry from the hierarchical design database 712 and theregister configuration rules from the DI rule database 1710. Knowing thestructure of the DIC from the DIC template database 720, the break-pointanalysis module 1712 creates the break-point database 602. Thebreak-point database 602 comprises all the rules for which the locationbreak-points are possible to be set. The break-point database 602 alsocomprises rules about mutual exclusivities between break-points due tohardware restrictions in the DIC. For example, a certain break-point maynot be used with another break-point because both break-points requirethe same hardware resource in the DIC.

Sixth, signal analysis module 1714 then reads the signalsampling/patching circuitry from the hierarchical design database 712and the register configuration rules from the DI rule database 1710, andknowing the structure of the DIC from the DIC template database 720, thesignal value database 604 is created. The signal value database 604comprises all the rules about mutual exclusivities between signal valuesfor sampling and/or patching due to hardware restrictions in the DIC.

Seventh, the DIC generation module 1716 then reads the DI rule database1710 and the DIC template database 720 and connects all triggerdetection circuitry and all signal sampling/patching circuitry to atrigger processing unit (TPU)(see FIG. 8). Also, the configuration andthe status registers, and the communication controller are added andconnected. The complete structure of the DIC is then written to thehierarchical design database 712 and the entire and complete rule set toconfigure the registers of the DIC is written to the DIC database 736.

Eighth, a DIC register-to-physical mapping module 1718 maps eachregister configuration and each status register in the DIC into anaddress space of physical memory in the design to produce the R2Pdatabase 614. For example, the physical memory could be implemented as aset of scan-chains, in which case the physical address of aconfiguration or status register would be given by the index of thescan-chain used and the bit position within the scan-chain.

Ninth, a DIC writer module 1720 produces the synthesizable HDLdescription of the DIC (e.g., DIC HDL description 318), defined by theconfiguration and status information in the DIC database 736 and the DICstructure stored in the hierarchical design database 712.

Tenth, the DIC writer module 1720 also reads in the original HDLdescription 304, annotates it with the information about the DIC fromthe hierarchical design database 712 and the DIC database 736, andwrites out the instrumented HDL description 316 (e.g., annotated HDLsource code) of the instrumented design for further processing bysynthesis and place-and-route tools.

Eleventh, to support regression testing of the instrumented design usingfunctional simulation, the optional DIC simulation model 322, includingthe necessary HDL wrapper files, is written by a DIC simulation modelgeneration module 1722.

Twelfth, a design constraint analysis module 1724 reads the designconstraint file 308 which holds all constraints created by the designer.The design constraint analysis module 1724 then adjusts the original setof constraints to produce the instrumented design constraint file 324for the instrumented design. Design constraint analysis is described ingreater detail below.

Annotating the HDL description adds the HDL description of the DIC tothe original HDL description and connects the DIC to the portions of theoriginal HDL description for which design visibility, design patching,and design control has been selected. The annotation can be performedautomatically. The result of the annotation is the instrumented HDLdescription. The instrumented HDL description is the original HDLdescription together with a small amount of HDL description added forthe DIC. The annotations may be added to the hierarchical original HDLdescription in two ways: distributed or monolithic. Distributedannotations are added to each hierarchical element of the original HDLdescription. Monolithic annotations are added to the top-level elementof the HDL design and then connect to other parts of the design. Sincedistributed annotations are more powerful and more complex thanmonolithic annotations, distributed annotations will be described indetail below.

A HDL description can be composed of one or more HDL Building Blocks(BBs). Similarly, the DIC is composed of one or more specially-tailoredHDL BBs, the DICBBs. One such DICBB can be inserted into each BB in theoriginal HDL description. The BB in the original HDL design is termedthe DICBB's host BB (HBB). An example provided below is a Verilogdescription of a simple building block which consists of some simplelogic.

module mod3( in1, in2, out ); input in1, in2; output out; assign out = (in1 > in2 ); endmodule

Another example provided below is a Verilog description of the HostBuilding Block (HBB) above following annotation (i.e., instrumentedbuilding block) to include one of the DICBBs with some simple buildingblocks which consist of one HBB and some simple logic. In the Veriloglanguage the DICBB is an instantiation of a specially-tailored DICVerilog module.

module mod3( in1, in2, out ); input in1, in2; output out; assign out = (in1 > in2 ); DIC_mod1 DIC_instance( in1, in2 ); endmodule moduleDIC_mod1( in1, in2 ); input in1, in2; // specially-tailored DIC goeshere endmodule

Each DICBB communicates with its associated HBB by connecting to theHBB's signals. Design visibility of a particular HDL identifier residingin a HBB can be accomplished by connecting the identifier to theassociated DICBB. The internal circuitry of the DICBB is created usingthe knowledge of the signal connections. This mechanism allows designvisibility, design patching, and design control to be supported by theDIC. The above example shows a DICBB connected to two HDL identifiers“in1” and “in2”. The circuitry inside DIC_mod1 can utilize the signalsfor the purpose of design visibility of one or both the signals and/orfor creating watch-points which monitor one or both of the signals.

If a symbolically-encoded HDL identifier is made visible, symbolicvalues can be displayed for it during HDL-based hardware debugging. Todo this, each symbolic value needs to be associated with the actualbinary code assigned to it during synthesis (116 in FIG. 1A.). Since itis desirable for the instrumentation to be independent of the synthesis,the HDL-based hardware debugger cannot rely on any information from thesynthesis about the association between binary codes and symbolicvalues. Consequently, each of the symbolic values must be connected tothe DICBB so that the circuitry inside the DICBB can explicitly know thebinary codes assigned to each symbolic value. During HDL-based hardwaredebugging, the encoding information is obtained from the instrumentedHDL design.

Break-points are supported by adding signals to the HBB which are activewhen the control flow which the break-point is modeling is active, andare inactive otherwise. The added signals are then connected to the DICassociated with the HBB and are used when the circuitry of the DIC iscreated. The following example shows the Verilog HDL fragment of a HBBwhich has simple control flow logic.

1 module mod4( in1, in2, out ); 2 input in1, in2; 3 output out; 4 5always@ ( in1 or in2 ) begin 6 if (( in1 == 1 ′b0 ) ∥ ( in2 == 1 ′b1 ) )begin 7 out = 1 ′b1; 8 end else begin 9 out = 1 ′b0; 10 end 11 end 12 13endmoduleLine numbers have been added to the above example for referencepurposes, the line numbers are not part of the Verilog description.There are two lines, line 6 and line 8, which can have a break-point.These lines correspond to the two control flow branches which arise fromthe “if” conditional statement on line 6.

The next example shows the Verilog HDL fragment of the above exampleannotated such that the added circuitry supports two break-points.

module mod4( in1, in2, out ); input in1, in2; output out; reg bp1, bp2;// Added during instrumentation always@ ( in1 or in2 ) begin bp1 = 1′b0; bp2 = 1 ′b0; if ( ( in1 == 1 ′b0 ) ∥ ( in2 == 1 ′b1 ) ) begin out =1 ′b1; bp1 = 1 ′b1; end else begin out = 1 ′b0; bp2 = 1 ′b1; end endDIC_mod2 DIC_instance( bp1, bp2 ); endmodule module DIC_mod2( bp1, bp2); input bp1, bp2; // specially-tailored DIC goes here endmoduleNote signals “bp1” and “bp2” have been added to the HBB. Each signal isactive (set to logical 1) only when the control flow branch that thesignal is modeling is active. The signals are connected to theassociated DICBB DIC_mod2 and can be used by the circuitry inside theDICBB to create break-point circuitry.

The DICBBs in the instrumented HDL design communicate with each other byconnecting to identifiers that have been added to their respective HBBsand which are also connected to the HBB's ports. The following exampleshows the Verilog HDL fragment which consists of two BBs. BB mod6 isinstantiated by BB.

module mod5( in1, in2, in3, out ); input in1, in2, in3; output out; wiretmp_out; assign out = ( in1 > tmp_out ); mod6 instance( in2, in3,tmp_out ); endmodule module mod6( com1, com2, out ); input com1, com2;output out; assign out = com1 {circumflex over ( )} com2; endmodule

The following example shows the Verilog HDL fragment of the aboveexample after being annotated.

module mod5( in1, in2, in3, out ); input in1, in2, in3; output out; wiretmp_out; wire DIC_com2; // Added during instrumentation assign out = (in1 > tmp_out ); mod6 instance( in2, in3, tmp_out, DIC_com2 ); DIC_mod3DIC_inst3( DIC_com2 ); endmodule module mod6( com1, com2, out, DIC_com1); input com1, com2; output out; inout DIC_com1; // Added duringinstrumentation assign out = com1 {circumflex over ( )} com2; DIC_mod4DIC_inst4( DIC_com1 ); endmoduleThe annotation consists of: (1) DICBBs DIC_mod3 and DIC_mod4 which havebeen added to their respective HBBs mod5 and mod6. (2) Signal DIC_com1which has been added to HBB mod6, added to the port list of HBB mod6,and connected to DIC_mod4. (3) Signal DIC_com2 which has been added tothe HBB mod5 and connected to the DIC_com1 port of the DIC_mod4 DICBBand to the DIC_mod3 DICBB. Consequently, the DIC mod_(—)4 DICBBcommunicates with the DIC_mod3 DICBB via the connection of DIC_mod4 tosignal DIC_com1 which is connected through port DIC₁₃ com1 of mod6 tosignal DIC_com2 of mod5 which is connected to DIC_mod3.

An original design of the electronic system (e.g., original HDLdescription) can be instrumented with either a complete DIC or a partialDIC. A complete DIC comprises a communication controller and a triggerprocessing unit (TPU). While a complete DIC, such as shown in FIG. 8,includes a communication controller and a TPU, a partial DIC does notinclude these components. An original HDL design may be instrumentedwith a partial DIC if it is to be used inside another instrumented HDLdesign which has a complete DIC. For example, an original HDLdescription could be instrumented with a partial DIC if it were to beused as a hard block. Although an instrumented HDL design with acomplete DIC can be used as a hard block if its communication controllerand TPU are disabled, this wastes hardware and thus space.

Instrumenting with a complete DIC can be accomplished by adding aspecial DICBB which is referred to as the “master” DICBB (MDICBB) whichcomprises a communication controller and a TPU. The MDICBB is placedinto an HBB of the original HDL design which allows the MDICBB tocommunicate with the host communication controller. For example, in aVerilog design, the HBB of the MDICBB would be the Verilog module whichis the top-level module in the design hierarchy—the HBB would be the onemodule in the design which is not instantiated in the Verilog design.The MDICBB is connected to the DICBB in the MDICBB's HBB. Consequently,the MDICBB can communicate with all other DICBBs in the instrumented HDLdesign so that said MDICBB can gather, process, and transmit to the hostcommunication controller information from the other DICBBs. Thefollowing example shows the Verilog HDL fragment of an above example fora basic building block (re module mod3) after it has been annotated.

module mod7( in1, in2, out, DIC_com3 ); input in1, in2; output out;inout DIC_com3; // Added during instrumentation assign out = ( in1 > in2); DIC_mod5 MDICBB_inst( DIC_com3 ); endmoduleNote that in this example, mod7 is the top-level module of the originalHDL design and DIC_mod5 is the MDICBB. DIC_mod5 communicates to theenvironment by connecting with signal DIC_com3 which has also been madea port of the HBB mod7.

In performing design constraint analysis, the design constraint analysismodule 1724 reads the design constraint file 308 which holds allconstraints that ensure the HDL design meets the area, delay, powerconsumption, routability, and/or testability specifications made by thedesigner of the electronic system. The design constraint analysis module1724 then analyzes the instrumented HDL design stored in thehierarchical design database 712 and adjusts the original set ofconstraints to the inserted DIC and possibly adds additionalconstraints. Both sets of the constraints together can be written intothe instrumented design constraint file 324 for the instrumented HDLdesign. The additional constraints attempt to minimize the impact of theDIC on the area, delay, power consumption, routability, and/ortestability of the HDL design.

FIG. 8 is a block diagram of a representative design instrumentationcircuit (DIC) according to one embodiment of the invention. Therepresentative DIC 800 includes a plurality of probe circuits, namelyprobe circuitry 802, probe circuitry 804 and probe circuitry 806. Theprobe circuitry 802-806 couple to a trigger processing unit 808. Thetrigger processing unit 808 is configurable circuitry which is used toprocess trigger events and issue corresponding trigger actions. Suchcorrespondance between the trigger events and the trigger actions can begiven as complex trigger conditions. A complex trigger condition can bea complex conditional expression between two or more trigger events.Propositional or temporal logic may be used to describe suchexpressions. The trigger processing unit 808 controls the ability of theDIC 800 to detect trigger conditions and to sample and/or patch signalvalues. The acts of detection, sampling and patching can be independentfrom each other. When trigger conditions are detected, the triggerprocessing unit 808 triggers sampling (visibility) or patching ofsignals within the DUT. In this regard, the probe circuitry 802-806couple to electrical signals within the DUT. Each of the probe circuitry802-806 is designed to perform a sampling of a signal, a modification toa signal, or a detection of a trigger condition. Typically, thesesignals or conditions are digital conditions. However, in the case inwhich the DUT includes analog and digital portions, the probe circuitry802 can include an analog-to-digital (A/D) converter 810 so as toconvert analog signals to digital signals prior to being received at theprobe circuitry 802. The representative DIC 800 also includes statusregisters 812 and configuration registers 814. The status registers 812store certain status information and the configuration registers 814store certain configuration information.

A communication controller 816 couples to the status registers 812 andthe configuration registers 814. Hence, a HDL-based hardware debugger isable to communicate with the DIC via the communication controller 816.More particularly, the HDL-based hardware debugger can read and setregisters within the status registers 812 as well as within theconfiguration registers 814. As a result, the communication controller816 allows configuration data to be sent to the DIC 800 and status datato be retrieved from the DIC 800. The communication controller 816 canimplement a method (i.e., run-time method) for externally reading andwriting the configuration registers 814 which configure the DIC 800 andexternally reading the status registers 812 (memory) which store thesample values. In one embodiment, the register values can be read or setusing a standard connection defined by the IEEE 1149.1 JTAG standard,available from the Institute of Electrical and Electronic Engineers inPiscataway, N.J., which is hereby incorporated by reference.

In order to maintain flexibility in HDL-based hardware debugging, theDIC is configurable at run-time. Externally configurable registers areused to change the detection of HDL-based trigger conditions and theselection of signals to be sampled and/or patched without the need tore-implement the design of the electronic system.

There is also a general need for the DIC to communicate with componentswhich are not instrumented. This external communication can beimplemented by connecting signals between the DIC and the othercomponents. One example would be an external signal that the DICactivates when any trigger condition is met. In another example, the DIChas external connections to notify and be notified about certainconditions which occur in an optional embedded processing unit (e.g.,CPU) and thus support hardware/software co-debugging.

Additional details concerning representative implementations for thetrigger processing unit 808 and the probe circuitry 802-806 are providedbelow. This circuitry is added to the original design of the electronicsystem. For the purposes of the discussion below, it is assumed that thehardware debugging system 100 of FIG. 1A is being used. Hence, thecircuitry for the DIC is added to the original HDL description asadditional HDL by the instrumentor 100 in producing the instrumented HDLdescription 112.

FIG. 9 describes a representative generic configurable circuitry 900which can implement design sampling and design patching according to oneembodiment of the invention. The circuitry 900 includes a register 902,a multiplexer 904, a tri-state register 906, and a storage 908. When theregister 902 is to be sampled, a selector signal 910 selects a registerinput 912 to drive the register 902 via multiplexor 904. A sample enablesignal 914 enables the tri-state buffer 906 to drive a register output916 onto a data bus 918. The storage 908 couples to the data bus 918 andcan thus store the value at the register output 916. For each successivesample, the value on an address bus 920 is incremented. Alternatively,when the circuitry 900 is to be patched, the address bus 920 selects theproper patch value from the storage 908. The multiplexor selector signal910 selects the data bus 918 to drive the input to the register 902 viathe multiplexor 904, and the selector signal 914 disables the tri-statebuffer 906, thereby driving the value from the storage 908 into theregister 902.

Storage 908 can also be implemented by sampling circuitry. Samplingcircuitry can use sets of registers or Random Access Memory (RAM) asstorage for sampling predetermined signals. The sampled values canthereafter be read from the storage and communicated to the HDL-basedhardware debugger. One implementation of storage 908 is a circularbuffer of depth M which continuously samples predetermined signals. Whena predetermined trigger action occurs, sampling is stopped. At whichpoint the circular buffer contains the M last values of all sampledsignals. To save circuitry, the sampling circuitry can be shared formany signals. For example, a configurable crossbar, implemented eitheras a full crossbar or as a multiplexor network, will allow many signalsto share the same storage (e.g., circular buffer).

Design patching can also be implemented by patching circuitry. Accordingto one embodiment, the patching circuitry provides a method for patchingpredetermined internal signal registers. For each register in the designof the electronic system which is to be made patchable, the patchingcircuitry can include a companion register and simple control circuitry.The companion register holds the patch value(s) and is run-timeconfigurable. The patching circuitry operates as follows: First, duringconfiguration of the DIC, the companion storage is loaded with a desiredvalue. Second, under the control of a particular trigger action, thepatching circuitry forces the patched register to take some configuredvalue from the companion storage. This patching circuitry thus allowspatching to be used for many applications including, but not limited to,debugging and fixing previously fabricated hardware.

Design visibility and design patching are controlled by particulartrigger actions which are determined by design control circuitry. FIG.10 illustrates a representative generic configurable trigger detectioncircuit 1000 according to one embodiment of the invention. The triggerdetection circuit 1000 operates to detect trigger conditions and issuetrigger events.

The trigger detection circuit 1000 includes a configurable triggerregister (TR) 1002 that stores a trigger value that is compared to amonitored signal (ISR) 1004 by a comparator 1006. The mode of thecomparator 1006 can be controlled by a configurable trigger comparisonregister (TCR) 1008. Examples of different comparison modes are test forequivalence, test for smaller-than, etc. The ability to configure thetrigger register (TR) 1002 and the trigger comparison register (TCR)1008 allows the electronic system designer the flexability to check fora wide variety of trigger conditions during HDL-based hardwaredebugging. A configurable trigger enable register (TER) 1010 allows thetrigger condition to be activated or disabled. If the trigger conditionimplemented by comparing the monitored signal (ISR) 1004 to the triggerregister (TR) 1002 is met and the trigger enable register (TER) 1010 isenabled, a trigger condition signal 1012 becomes active to denote atrigger event. A trigger detected register (TDR) 1014 can be used tostore such a trigger event, which can be subsequently read duringHDL-based hardware debugging to determine whether a trigger event hasoccurred.

While FIG. 10 illustrates the representative generic configurabletrigger detection circuit 1000, for various more specific situations,specialized design control circuitry provides more efficient hardware.Examples of these specific situations, including state based FiniteState Machines (FSMs), transition based FSMs, data-path registers, andtemporal logic, are described below.

State based FSM design control circuitry provides a configurable methodto detect whether an FSM is in a particular state—a condition whichdepends on the value of the FSM's state register. For simplicity, aone-hot encoded state-machine is described herein. For other stateencodings, the design control circuitry can be implemented similarly.FIG. 11 illustrates a representative state based FSM design controlcircuit 100 according to one embodiment of the invention. For each FSMstate register that is to be instrumented to detect particular states,the state based FSM design control circuit 1100 is added. Ato-be-instrumented one-hot encoded FSM 1102 has a state register 1104which is n bits wide and which is sensitive to the clock signal 1106.The state based FSM design control circuit 1100 that is added includes atrigger register 100 which has the same bit-width n as the stateregister 1104 and which is sensitive to the same clock signal 1106. Anoutput 1112 of the state register 1104 is compared to an output 114 ofthe trigger register 110 using a combinatorial network 1116. Thecombinatorial network 1116 implements a trigger condition signal 1118.The trigger condition signal 1118 produced by the state based FSM designcontrol circuit 1100 can be a single bit output function and can bedescribed in its behavior by the following Verilog code:

module m1116 (n1112, n1114, n1118); parameter n = 32; input [n−1:0]n1112; input [n−1:0] n1112; output n1118; wire n1118 = | (n1112 &n1114); endmoduleThus to detect a particular current state in the one-hot encoded FSM102, one can set the corresponding bit in the trigger register 110 tological “1”. The trigger register 1110 can be configured withappropriate values through a connection (link) 1120. The triggercondition signal 1118 will then be logically “1” to denote the triggerevent.

Transition based FSM design control circuitry provides a configurablemethod to detect whether a FSM is undergoing a particular statetransition—a condition which depends on the value of the state registerand also on the activity and values of the input signals of the FSM. Forsimplicity, a one-hot encoded state-machine is described herein. Forother state encodings, the design control circuitry can be implementedsimilarly.

FIG. 12 illustrates a representative transition based FSM design controlcircuit 1200 according to one embodiment of the invention. For each FSMthat is to be instrumented for detecting particular state transitions,the transition based FSM design control circuit 1200 is added. Theto-be-instrumented one-hot encoded FSM 1202 has a state register 1204which is n bits wide and which is sensitive to a clock signal 1206. Thetransition based FSM design control circuit 1200 that is added includesa trigger register 1208 which is sensitive to the clock signal 1206, andis o bits wide where o is the number of different state transitions ofthe FSM 1202. A combinatorial network 1210 performs a unique one-hotencoding of each different state transition into output 1212 and thus isconnected to the n bit wide output 1214 of the state register 1204 aswell as to the m bit wide input 1214 of the FSM 1202. A combinatorialnetwork 1216 is connected to a o bit wide output 1218 of the triggerregister 1208 and the o bit wide output 1212 of the combinatorialnetwork 1210. A trigger condition signal 1220 is the single bit outputof the combinatorial network 1216 and can be described in its behaviorby the following Verilog code:

module m1216 (n1218, n1212, n1220); parameter o = 32; input [o−1:0]n1218; input [o−1:0] n1212; output n1220; wire n1220 = | (n1218 &n1212); endmoduleThus to detect a particular state transition in the one-hot encoded FSM1202, the bit in the trigger register 1208 corresponding to the one-hotcode of the particular state transition must be set to logical “1”. A obit wide connection 1222 can be used to configure the trigger register1208 with appropriate values. The trigger condition signal 1220 becomesa logical “1” whenever a state transition is active, which denotes thetrigger event.

For data-path registers, data-path register design control circuitryprovides a configurable method to detect whether a data-path registerhas a particular current value, whether a data-path register has aparticular relationship to other values, or whether a data-path registerhas just changed its value. FIG. 13 illustrates a representativedata-path register design control circuit 1300 according to oneembodiment of the invention. The data-path register design controlcircuit 1300 is coupled to a data-path register 1302 which is sensitiveto a clock signal 1304 and which latches the n bit wide input net 1306into a n bit wide output net 1308. The data-path register design controlcircuit 1300 includes one or more of n+1 bit wide trigger registers1310, 1312, 1314 which all are sensitive to the clock signal 1304. The nbit wide output 1308 of the data-path register 1302 and all the n+1 bitwide outputs 1316, 1318, 1320 of the trigger registers 1310, 1312, 1314are then connected as inputs to a combinatorial network 1322. Thecombinatorial network 1322 provides configurable pair-wise checkingrelations between the current value of the data-path register 1302 andthe n least significant bits of one of the trigger registers 1310, 1312,1314. The relation being checked for can be the equality, non-equality,less than, greater than, etc., and such relation can be determined bythe user. The most significant bit within each of the n+1 bit widetrigger registers 1310, 1312, 1314 is used for enabling (if the bit isset to “1”) or disabling (if the bit is set to “0”) the checking of therelation and can be described in its behavior by the following Verilogcode:

module m1322 (n1308, n1316, n1318, n1320, n1324); parameter n = 32;input [n−1:0] n1308; input [n:0] n1316; input [n:0] n1318; input [n:0]n1320; output n1324; wire check0 = n1316[n] & compare0(n12190,n1316[n−1:0]); wire check1 = n1318[n] & compare1(n12190, n1318[n−1:0));wire check2 = n1320[n] & compare2(n12190, n1320[n−1:0]); wire n1324 =check0 | check1 | check2; endmoduleIf one of the relations is satisfied, the trigger condition signal 1324becomes logical “1” to denote a trigger event.

Temporal logic is an extension of conventional propositional logic whichincorporates special operators that operate with time as a variable.Using temporal logic, one can specify how functions behave as timeprogresses. In particular, temporal logic statements can make assertionsabout values and relationships in the past, present, and the future. Asubset of temporal logic can be used to describe interdependenciesbetween trigger events over a certain time period relative to a givenevent, at one or more cycles, or for trigger events of the past. FIG. 14illustrates a representative design control circuit 1400 according toone embodiment of the invention that can be used to implement temporallogic needed for relationships which include signals or trigger eventsfrom previous clock cycles. The trigger condition signal 1402 can bedelayed by a configurable number of cycles of clock 1404 using delayregisters 1406, 1408 and 1410. A multiplexor 1412, under the control ofa trigger control register (TCR) 1414, selects which current or previousvalue of the signal 1402 is sent to output 1416. The output 1416 can beused as an input to temporal logic equations.

The selection of the signal to drive the clock input 1404 of the delayregisters 1406, 1408 and 1410 offers powerful functionality as follows.First, when one of the system clock signals is connected to the clockinput 1404 of the delay registers 1406, 1408 and 1410, events can bedelayed relative to the system clock. Second, when a particular triggercondition-signal is connected to the clock input 1404 of the delayregisters 1406, 1408 and 1410, the signal 1402 is delayed relative tothe trigger condition signal.

To implement the capability to control the processing of particulartrigger events over relatively longer periods of time, counters can beused. The counters operate by loading a configured value, counting downfrom the loaded value to zero, and then issuing an event when zero isreached. The selection of the signal to drive the clock input of thecounter offers powerful functionality. First, when one of the systemclock signals is connected to the clock input of the counter, triggerevents can be delayed relative to the system clock. Hence, triggerevents can be made to depend on the system time. For example, triggerevents might be enabled for a certain time period and become disabledotherwise, or become enabled after some time period. Second, when aparticular trigger condition signal is connected to the clock input ofthe counter registers, the operation of the counter is dependent on thetrigger condition signal.

As noted previously, a DIC includes a trigger processing unit (TPU) toprocess all incoming trigger events and to issue appropriate outgoingtrigger actions based on the incoming trigger events. The TPU provides aconfigurable method for calculating complex trigger combinations andother relationships between one or more of the trigger events to producethe trigger actions. The trigger events for processing by the TPU arethe trigger condition signals of the design control circuitry of the DICas described above or signals from circuitry external to the DIC. Forexample, in hardware/software codebugging of embedded CPUs, suchexternal signals may be the error signals of the CPUs. In anotherexample, when multiple DICs are coupled (e.g., daisy-chained) to supportdebugging of multi-chip systems, another such trigger event could be thetrigger action generated by the other DIC.

In any case, trigger actions computed by the TPU can be used for (butnot limited to) the following uses: (i) determine the beginning and/orthe end of the sampling period of one or more sampled signals for designvisibility; (ii) initiate the overwrite of one or more patch registersfor design patching; (iii) provide a sampling clock in case none of thesystem clock signals shall be used; (iv) notify the communicationcontroller within the DIC that one or more trigger events have occurred,thereby notifying the HDL-based hardware debugger; (v) communicatetrigger events outside the electronic system to attached devices throughexternally connected signals; (vi) communicate with sub-systems insidethe electronic system (e.g., during hardware/software co-debugging ofembedded CPUs, trigger actions may be used as notification signals goinginto interrupt inputs of the CPUs); and (vii) connecting with thetrigger event inputs of another DIC (e.g., when multiple DICs aredaisy-chained to support debugging of multi-chip systems).

A trigger action can also be used to trigger multiple components. Atrigger action group is a unique combination which comprises one or moreunits of design visibility and/or design patching circuitry which is/arecontrolled by the same trigger action. The internal structure of the TPUcan be (but is not limited to) the following: (i) A simple TPU can beused where each trigger event issues exactly one and only one triggeraction. (ii) A TPU can include a configurable combinational networkwhere all the trigger events are inputs to the combinational network andtrigger actions are outputs of the combinational network. For example,the configurability can be provided by a Random Access Memory (RAM)which can be configured by the HDL-based hardware debugger and act aslook-up tables to implement a wide range of different booleancombinational functions. (iii) A TPU can be a configurable finite statemachine where trigger events are inputs to the state machine and triggeractions are outputs of the state machine. In one example, theconfigurability is provided by a set of registers or a Random AccessMemory (RAM) which defines the behavior of the finite state machine andwhich can be configured by the HDL-based hardware debugger. (iv) A TPUcan be a pipelined CPU. The trigger events to be processed can flow intothe TPU as input data, the trigger actions to be issued can berepresented as output data of the CPU, the instruction code of the CPUcan implement complex relationships between the trigger events whichproduce the trigger actions. The trigger action computations may not befinished until a number of clock cycles after the the trigger eventsflow into the TPU. Consequently, the design visibility circuitry shouldhave enough memory to store the data which corresponds to the latenttrigger actions. Also, the HDL-based hardware debugger should understandthe latency of the trigger actions to correctly associate non-latentsampling data to the latent trigger actions.

Although the instrumentation techniques discussed above pertain todigital signals, it should be understood that these same techniques canalso apply to the digital portion of mixed-signal designs. Stillfurther, with respect to the analog portion of mixed signal designs, ananalog signal can be made visible and also can be used to form triggerconditions. In one embodiment, the analog signal can be made visible byconnecting it to an analog-to-digital converter (ADC) which has beenadded to the DIC. The digital outputs of the analog-to-digital convertercan then be monitored using the design visibility techniques previouslymentioned. A user interface can convert the digital data back to ananalog representation for display to the designer. The analog signal canbe used to form a trigger condition by expressing the trigger conditionin terms of the digital outputs of the analog-to-digital converter.Additionally, a graphical user interface (e.g., the graphical userinterface 704 of FIG. 7A) can convert an analog trigger threshold set bythe electronic system designer to an appropriate set of digital valueswhich can be used to configure the trigger condition.

As noted above, the DIC can be provided within the DUT in either acentralized or distributed manner. More particularly, in order tominimize the impact of the DIC on the electronic system hardware, theDIC can be structured as a monolithic block or as distributed circuitry.The option to choose between these two structures allows the trade-offof area, delay, power consumption, routability, and/or testability ofthe hardware required for the DIC. As a monolithic block, all signals tobe monitored for trigger detection or to be sampled and/or patched arephysically routed from their source to the DIC region where the triggercondition detection and/or the signal value sampling/patching isphysically placed. As a distributed DIC, the circuitry comprising theDIC is placed close to the signals used for triggering, sampling, and/orpatching. For a monolithic DIC block, resource sharing to reduce thearea and power consumption overhead becomes an option. These gains areoffset by the increased delay and area needed for the long routes to theDIC block. A distributed DIC, however, will not offer any resourcesharing, but promises short routes and therefore less impact on thedelays and the routability.

Moreover, the monolithic or the distributed structure for the triggerdetection circuitry can be selected independently from the monolithic orthe distributed structure for the signal value sampling, patching, andstoring circuitry. A special case of DIC structure is a DIC withmonolithic trigger detection circuitry and monolithic signal valuesampling and/or patching circuitry. The trigger detection and signalvalue sampling and/or patching circuitry share the same signals. In sucha structure, trigger conditions can only be expressed using signalswhich are also sampled.

FIG. 18 is a flow diagram of HDL-based hardware debugging processing1800 according to one embodiment of the invention. The hardwaredebugging processing 1800 is performed after the electronic system hasbeen fabricated to include a customized DIC.

The hardware debugging processing 1800 initially starts when theHDL-based hardware debugger is initiated 1802 on a host computer. TheHDL-based hardware debugger is preferably a software program thatoperates on the host computer. Next, the host computer couples 1804 withthe operating fabricated electronic system. For example, this coupling1804 can occur through cables that couple the host computer to thecommunication controller 816 of the DIC 800. The DIC 800 can beconsidered part of the DUT or part of the electronic system. Thereafter,when debugging is to be performed, the DIC is configured 1806 forexamination and/or modification of the fabricated electronic system.Here, for example, the configuration registers 814 of the DIC 800 can beconfigured 1806 to perform the appropriate examination and/ormodification of the fabricated electronic system (namely, the DUTtherein). Next, the fabricated electronic system is operated 1808 in thetarget environment and at speed. In other words, the fabricatedelectronic system is the actual hardware that is produced and thenoperated in its normal operating environment (target environment) and atits normal speed of operation. Hence, this facilitates debugging of thehardware (e.g., fabricated electronic system) in its actual environmentand at its actual speed. Thereafter, HDL-based hardware debugging isperformed 1810 on the operating fabricated electronic system. TheHDL-based hardware debugging thus interacts with the user to referencelines or areas of the HDL description associated with the electronicsystem. As a result, users are able to analyze, diagnose, and debugfunctional failures of the electronic system at the HDL level, and usersare able to interact with the electronic system at the HDL level to settrigger conditions and examine and/or modify the electronic systemsbehavior. Following the operation 1810, the hardware debuggingprocessing 1800 is complete and ends.

Once the electronic system 104 having the DUT 102 with the incorporatedDIC 106 has been fabricated, the HDL-based hardware debugger 122 canoperate to debug the DUT 102. The HDL-based hardware debugger 122interacts with a user through one or more user interfaces and interactswith the DIC 106 through a host communication controller. The HDL-basedhardware debugger 122 can, for example, operate to support one or moreof the following functions: (1) browsing the original HDL descriptionfor the HDL design; (2) activating particular trigger conditions out ofthe set of possible trigger conditions implemented in the DIC; (3)de-activating particular trigger conditions out of the set of activatedtrigger conditions; (4) temporarily disabling trigger conditions out ofthe set of previously activated trigger conditions; (5) enablingtemporarily disabled trigger conditions; (6) activating signals to besampled out of the set of possible signals in accordance with theimplementation of the DIC; (7) de-activating signals out of the set ofsignals which were activated for sampling; (8) temporarily disablingsignals out of the set of signals activated for sampling; (9) enablingtemporarily disabled sampling signals; (10) activating signals to bepatched out of the set of possible signals in accordance with theimplementation of the DIC; (11) de-activating signals out of the set ofto-be-patched signals; (12) temporarily disabling signals out of the setof signals activated for patching; (13) enabling temporarily disabledpatching signals; (14) translating HDL-based trigger conditions given bythe designer to the proper register configuration of the DIC; (15)associating trigger conditions with the clock/begin/end events ofsampling and/or patching circuitry; (16) controlling execution of theDIC at run-time such as starting, stopping, single-stepping, running fora given number of cycles, resetting, etc.; (17) capturing the entire orthe partial state of the HDL design, downloading it off the DIC, andstoring it in the proper databases; (18) translating the DIC statusregisters and the sampled signal values back to the HDL source code;(19) displaying the DIC status in one or more formats, including thecurrent data as well as data history; (20) displaying the signalsampling data in one or more formats, including the current data as wellas data history; (21) interfacing with other debugging tools, such asfunctional simulators and software debuggers; (22) performing licensechecks to determine the legality of running the DIC; and (23) performingversion checks of the DIC, and consistency checks of the DIC and thedesign instrumentation database.

FIG. 19 is a data flow diagram of a debugging process 1900 performed bya HDL-based hardware debugger according to one embodiment of theinvention. An activation user interface 1902 displays the original HDLdescription 304 and provides the designer with a method to activate andde-activate break-points and other trigger conditions and to activateand de-activate signals for sampling and/or patching. Once signals forsampling and/or patching are activated, the activations may be groupedtogether to form a unique trigger action group. Each trigger actiongroup then gets one or more trigger condition associated therewith thatcontrol the trigger action group. These activations are used by theHDL-based hardware debugger to configure the DIC at run-time.

Additional details on trigger condition activations are as follows. Thestructure of the DIC limits trigger conditions to the set of locations(for break-points) and explicit trigger condition expressions (forwatch-points) in the HDL description 304 which were selected or impliedduring design instrumentation. Additional hardware restrictions of theDIC may also limit the activation of trigger conditions in certaincases. In accordance with the structure of the DIC, an activebreak-point database 1904 lists the status type of each triggercondition implemented in the DIC as one of: possible (i.e., thecorresponding trigger condition can be activated); activated (i.e.,designer has activated), and forbidden (i.e., the trigger conditioncannot be activated due to a mutual exclusivity relationship with one ormore currently activated trigger conditions. Initially, a break-pointmanager 1906 copies over the set of trigger conditions from thebreak-point database 602 into the active break-point database 1904 andmarks all entries as possible. To guide the designer in his activations,the user interface 1902 reads the active break-point database 1904 anddisplays the current status for each trigger condition listed. Wheneverthe designer activates a trigger condition out of the set of possibletrigger conditions, the user interface 1902 marks the trigger conditionas activated in the active break-point database 1904 and notifies thebreak-point manager 1906. Likewise, whenever the designer de-activates atrigger condition out of the set of activated trigger conditions, theuser interface 1902 marks the trigger condition as de-activated in theactive break-point database 1904 and notifies the break-point manager1906. The break-point manager 1906 applies the rules in the break-pointdatabase 602 which describe the interdependencies of all triggerconditions and their mutual exclusivity to the current setting in theactive break-point database 1904. Under such rules, any triggercondition which is mutually exclusive with the activated (orde-activated) trigger condition is marked as forbidden (or possible), asappropriate.

Additional details on signal sampling and patching activation are asfollows. To utilize the signal sampling and patching circuitry in theDIC, the designer activates signals for sampling and/or patching, groupsthese activations into one or more trigger action groups, and associatesone or more trigger conditions by which each trigger action group iscontrolled. For patching, the designer also specifies one or more patchvalues and the trigger condition settings under which each patch valueshall be applied. To reflect limitations of the DIC in the sharing ofsampling and/or patching resources, a similar activation mechanism forsignal values exists as for trigger conditions. An active signal valuedatabase 1908 lists the status type of each signal that has been madevisible as one of: possible (i.e., the signal can be activated forsampling and/or patching); activated (designer has activated); andforbidden (i.e., the signal cannot be sampled/patched due to a mutualexclusivity relationship with one or more currently sampled/patchedsignals). Initially, a signal value manager 1910 copies over the set ofall signals listed in the signal value database 604 into the activesignal value database 1908 and marks them as possible. To guide thedesigner in making activations, the user interface 1902 reads the activesignal value database 1908 and displays the current status for eachsignal listed. Whenever the designer activates a signal out of the setof possible signals, the user interface 1902 marks the signal asactivated in the active signal value database 1908 and notifies thesignal value manager 1910. Likewise, whenever the designer de-activatesa signal out of the set of possible signals, the user interface 1902marks the signal as de-activated in the active signal value database1908 and notifies the signal value manager 1910. The signal valuemanager 1910 applies the rules in the signal value database 604 whichdescribe the interdependencies of all signals and their mutualexclusivity to the current setting in the active signal value database1908. Under these rules, any signal which is mutually exclusive with theactivated or de-activated signal is marked as forbidden or possible, asappropriate.

After the various activations have been made with respect to run-timeconfiguration of the DIC, the designer notifies a run-time controller1912 through a run-time user interface 1914 to configure the DIC. Usingthe rules in the DIC database 736, a DIC configuration manager 1916translates the information in the active break-point database 1904 andthe active signal value database 1908 to the proper values for the DIC'sconfiguration registers and writes a DIC configuration file to a DICconfiguration database 1918. A register-to-physical address translator1920 (R2P translator) then accesses the R2P database 614 (i.e.,register-to-physical address translation table) and translates the DICconfiguration file to the proper physical memory locations within theDIC and produces a raw configuration file 1922. The raw configurationfile 1922 is then uploaded into the DIC by a host communicationcontroller 1924 that communicates with the client communicationcontroller 816 inside the DIC 800. This configures the DIC to detect theproper trigger conditions and to sample/patch the proper signals asspecified by the designer. For efficiency, the host communicationcontroller 1924 provides a method of handling incrementally the rawconfiguration file 1922 and uploads only changed data into the DIC 800.The host communication controller 1924 communicates with the clientcommunication controller 816 by transmitting control signals, uploadingdata, receiving control signals, and downloading data via one or moreconnections (communication links). When at least one trigger conditionis detected, the trigger processing unit 808 inside the DIC 800 informsthe run-time controller 1912 via a communication link connected to thehost communication controller 1924.

The HDL-based hardware debugger also performs signal value examination.When the HDL-based hardware debugger has been notified that one or moretrigger conditions have been detected, the host communication controller1924 downloads data from the DIC and stores it in a raw status file1926. This raw status data is then split by the R2P translator 1920 intodata from the DIC status registers and data from the signal value samplememory. The data from the DIC status registers is stored in a DIC statusdatabase 1928. The DIC configuration manager 1916 accesses the DICdatabase 736 and the active break-point database 1904 and determineswhich of the activated trigger conditions were actually detected. Thedetected trigger conditions are then marked as triggered in the activebreak-point database 1904. The activation user interface 1902 thereafterdisplays the detected trigger conditions as marked. On the other hand,the data (values) of the sampled signals from the signal value samplememory are stored in a system state database 1930. A history manager1932 picks up values of the sampled signals from the system statedatabase 1930, analyzes the history based on the sample clock periods,and appends them to a signal value history database 1934. The signalvalue history database 1934 provides a method of storing sampled signalsfor particular sample times. A signal value resolver 1936 reads thesignal value history database 1934, resolves the data back to HDLidentifiers by applying the resolution rules of the cross-referencedatabase 612, and writes the data into a global signal value database1938. Any re-organization and/or transformation of the signal data tosupport HDL identifiers with complex values (for example multi-bit orsymbolically encoded values) can also be performed by the signal valueresolver 1936. Signals, whether selected or implied, which have not beendirectly sampled but which can be derived from sampled values, arecalculated by the signal value resolver 1936 and stored in the globalsignal value database 1938. The global signal value database 1938comprises the current value and the value history of all the signals,sampled and/or derived. The value history can be used for display to thedesigner or for further processing. A format translator 1942 accessesthe global signal value database 1938 and translates the data into oneor more different file formats. For example, the format translator 1942can produce vector change dump files 1944, wave vector files 1946, ordebug data files 1948 suitable for further processing by third partytools such as simulators. The display manager 1940 gets directions froma display user interface 1950 about which values to query for displayfrom the global signal value database 1938. The display user interface1950 uses the original HDL 304 to provide a method for HDL-based signalexamination for the designer.

When software debugging is also to be performed, the debugging process1900 can include a software debugger interface 1960 and a softwaredebugger 1962. Additional details on software debugging are providedbelow with respect to FIG. 20.

Still further, the HDL-based hardware debugger can perform check-pointprocessing. The system state of the HDL design including the DIC isrepresented by the values of the electronic system's registers andinputs. The HDL-based hardware debugger provides a method for saving andrestoring the system state to the system state database 1930. Dependingon whether all the registers and inputs are sampled, or only some ofthem, the system state can be saved in full or partially. Sometimes apartial system state is sufficient, sometimes the full system state isnecessary. The capability to save and restore the electronic system'sstate can be used for many applications. As examples, one applicationcan set the electronic system to a known state during HDL-based hardwaredebugging, and another application can integrate the present inventionwith functional simulators.

HDL-based hardware debugging using the sampling and trigger detectionmethods described in the present invention still may not give everydetail of every internal signal like an event-driven functionalsimulator may give. Thus, it may be desirable to combine both approachesand have one system, where the HDL-based hardware debugging techniquesare used when there is a need for a high execution speed and/orreal-time behavior, and where a functional simulator is used for timeperiods which are not speed-critical but where a great level of detailis needed. In order to combine both styles, the HDL-based hardwaredebugger described in FIG. 19 provides a way to exchange informationabout the system state with a functional simulator. Most functionalsimulators provide a method for saving the simulation state of asimulation model of the HDL design in a checkpoint file using a varietyof different file formats. The file formats can be processed by acheckpoint manager 1952. For uploading the state of the simulation modelinto the HDL-based hardware debugger, a simulator checkpoint input file1954 is translated by the checkpoint manager 1952 using thecross-reference database 612 and stored in the system state database1930. To start the functional simulation from a given state of the HDLdesign, the checkpoint manager 1952, using the cross-reference database612, can convert the contents of the system state database 1930 into asimulator checkpoint output file 1956 in a format suitable for afunctional simulator. A checkpoint file 1958 can be used for storing andretrieving the system state of the DUT, for example, for subsequent runsof the HDL-based hardware debugger.

Still further, the HDL-based hardware debugger can perform mismatchprocessing. The mismatches can occur between different runs of the DUT.In some situations it may be useful to find mismatches in the samplingdata gained from running the same version of the DUT under differentconditions. For example, this could be used for verifying that thefunctionality of an HDL design has not changed after the HDL design hasbeen modified. In some other situations it may be useful to findmismatches in the sampling data gained from running two differentversions of the same DUT under identical conditions. To make it easierfor the designer to understand any mismatches found, the HDL-basedhardware debugger can relate mismatches back to the original HDLdescription and display both sets of signal values. The mismatches canalso occur between the HDL description and the DUT. In some situationsit may be useful to compare the functional behavior of a fabricatedelectronic system with the functional behavior of the HDL description ofthe electronic system. A mismatch in the comparison means that some stepin the design flow was incorrect. The electronic system need not befully instrumented since some functional mismatches can be caught withpartial instrumentation.

A representative method for performing such a comparison is as follows:First, the HDL design is instrumented. The instrumentation is mostuseful when the design visibility covers the entire system state.Second, with the instrumentation enabled, run the DUT in an environmentand at a speed for which it was targeted. Third, store all sample datagained from the operation of the DUT. Fourth, starting with the earliestclock cycle for which sample data is available, format the sample dataso that it will be accepted by a functional simulator. Fifth, use theformatted data to set the initial state of the HDL design in afunctional simulation of the HDL design. If the HDL design was partiallyinstrumented, substitute the appropriate “UNKNOWN” simulation value forany un-instrumented inputs or storage elements in the circuit. Sixth,use the functional simulator to calculate the values of the storageelements in the next clock cycle given the initial state set above.Seventh, compare the calculated values of the storage elements with thesample data for the next clock cycle and note any mismatches. If the HDLDesign was partially instrumented, any comparisons to an “UNKNOWN” valueare NOT a mismatch. Eighth, take the sample data for the inputs andstorage elements from the next cycle, format as appropriate, and usesuch to re-set the initial state of the functional simulator. Ninth,while there is more design visibility data left, return to the sixthoperation. The mismatches found in the seventh operation are potentialproblems and should be investigated by the designer. To make it easierfor the designer to understand any mismatches found, the HDL-basedhardware debugger can relate the mismatches back to the original HDLdescription and display both sets of signal values.

In the above representative method, mismatches are found by comparingthe sampling data with the values calculated from the HDL description bya functional simulator. Obviously, the full power and generality of afunctional simulator is not required here. Any method that can calculatedelay-independent functional values from an HDL description can be usedto find mismatches. For example, the cross-reference database cancontain a representation of the necessary function of the HDLdescription and can be used to calculate the values directly.

FIG. 20 is a block diagram of a hardware/software co-debugging system2000 according to one embodiment of the invention. The hardware/softwareco-debugging system 2000 is generally similar to the hardware debuggingsystem 100 of FIG. 1A or the hardware debugging system 150 of FIG. 1B,but the DUT 102 includes not only the DIC 106 but also a CentralProcessing Unit (CPU) 2002. The hardware/software co-debugging system2000 thus permits debugging not only software that runs on the CPU 2002but also debugging the DUT 102. For debugging the software that runs onthe CPU 2002, a software debugger 2004 is used. The software debugger2004 is a software program that runs on a host computer and controls andobserves the execution of the computer software code which runs on theembedded CPU 2002. For example, the software debugger 2004 can be thesoftware debugger 1962 illustrated in FIG. 19. The software debugger2004 allows program break-points to be set. Those program break-pointsdefine the condition upon which the program execution is halted suchthat the designer can examine the operation of the software program. Ifthe embedded system (CPU 2002) cannot be halted, the software debugger2004 takes a snapshot of the software program's state for examinationinstead.

FIG. 21 is a block diagram of a hardware/software co-debugging system2100 according to one embodiment of the invention. The hardware/softwareco-debugging system 2100 is generally similar to the hardware/softwareco-debugging system 2000 of FIG. 20 with the addition of an In-CircuitEmulator (ICE) 2102. The ICE 2102 interfaces the software debugger 2004with the CPU 2002. The ICE 2102 is, more generally, a debuggerinterface. An example of such a debugger interface is described in “TheNexus 5001 Forum Standard for a Global Embedded Processor DebugInterface,” which is available by the IEEE-ISTO in Piscataway, N.J., andwhich is hereby incorporated by reference. It should also be noted thatas shown in FIG. 21 the CPU 2002 may not be part of the DUT 102. Ingeneral, the software being debugged can execute on the CPU 2002. TheCPU 2002 need not be within the DUT 102. In other words, the CPU 2002can be part of the electronic system 104 or can even be external to theelectronic system 104 if coupled thereto.

Concurrent debugging of the HDL design and the CPU software deals withthe following two cases: (i) a trigger condition set in the HDL-basedhardware debugger and detected at run-time in the DIC; and (ii) aprogram break-point is set in the software debugger 2004 and detected inthe CPU 2002 and/or the ICE 2102.

The setting and detecting of at least one trigger condition in the DICand examining the operation of the HDL design and/or the softwareprogram can be done in the following operations. First, a triggercondition is set in the HDL-based hardware debugger (HHD) 122. Second,the HHD 122 configures the DIC 106 via a communication link 2104. Third,if the trigger condition is met, one or more trigger actions are issuedin the DIC 106. One trigger action in the DIC 106 notifies the HHD 122via the communication link 2104. One trigger action in the DIC 106notifies the CPU 2002 via a communication link 2106. On the CPU side,the communication link 2106 may be connected to an interrupt input.Fourth, the HHD 122 then downloads the DIC status and the sample valuesfor processing and display. Fifth, the CPU 2002 then notifies the ICE2102 via a communication link 2108. Sixth, the ICE 2102 then notifiesthe software debugger 2004 via the communication link 2110 that atrigger condition was detected. Alternatively, the HHD 122 can directlynotify the software debugger 2004 via the software debugger interface1960. Seventh, the software debugger 2004 then takes a snapshot of thecurrent status of the software program and/or halts the program'sexecution. Eighth, the status and the history of the operation of theHDL design and the software program can then be examined in the userinterface 2116.

The setting and detecting of at least one trigger condition in thesoftware debugger 2004 and examining the operation of the HDL designand/or the software program can be done in the following operations.First, a program break-point is set in the software debugger 2004.Second, the software debugger 2004 sets up the ICE 2102 via thecommunication link 2110. The ICE 2102 monitors some internal portions ofthe CPU 2002 (for example the instruction pointer counter) to determinewhether the program break-point is reached. Third, if the programbreak-point is reached, the following actions are issued: (i) one actionissued by the ICE 2102 notifies the software debugger 2004 via thecommunication link 2110; and (ii) another action issued by the CPU 2002notifies the DIC 106 via the communication link 2106. On the DIC's sidethe communication link 2106 can be connected to an external triggerevent input. Fourth, the software debugger 2004 then takes a snapshot ofthe current status of the software program and/or halts the program'sexecution. Fifth, the DIC 106 then processes the trigger event(s) andinforms the HHD 122 via the communication link 2104. Sixth, the HHD 122then downloads the DIC status and the sample values for processing anddisplay. Seventh, the status and the history of the operation of the HDLdesign and the software program can then be examined in the userinterface 2116. Depending on the debugging tools utilized, the userinterface 2116 can be either integrated into the HHD 122 and/or into thesoftware debugger 2004.

The hardware debugging system according to the invention can havenumerous features. The hardware debugging system can, for example, bethe hardware debugging system 100 illustrated in FIG. 1A or the hardwaredebugging system 150 illustrated in FIG. 1B. Exemplary features of thehardware debugging system might include one or more of those featuresexamined below.

One exemplary feature pertains to HDL-based hardware debugging. Whiledebugging an electronic system, the values of numerous signals may beexamined. Relating these values of numerous signals back to the HDLdescription of the electronic system allows a user (e.g., designer) togain an understanding of the operation of the electronic system. Thisenables the debugging to be performed at the same level of abstractionand using the same text description that the designer of the electronicsystem used to design and implement the electronic system. During thedesign phase of an electronic system, there are many transformationsmade to the HDL description to produce the fabricated electronic system.While such transformations conventionally often make it very difficultto difficult to relate a signal in the fabricated electronic system tothe HDL description, the invention is able to relate the signalsautomatically and thus provides an efficient and effective approach todebugging the electronic system.

Another exemplary feature pertains to the ability to debug in a targetenvironment at target speed. Performing HDL-based hardware debugging,while the electronic system is running in an environment and at a speedfor which the HDL design is targeted, provides the following benefits:high processing bandwidth, real-time debugging, and no need fortestbenches. During debugging, all operations may take the same time asin normal (non-debugging) operation which provides high processingbandwidth. For example, booting an operating system is a task whichrequires many clock cycles and is usually too time consuming to be donein functional simulation. In HDL-based hardware debugging, booting maytake the same amount of time which it takes in normal (non-debugging)operation of the electronic system. Consequently, the designer canre-run the booting as often as necessary to fully debug the electronicsystem. Real-time debugging is useful for debugging electronic systemswhich have to maintain a specified real-time behavior in the sense thatcertain operations must be performed within a very well-defined timelimit. Further, since a failure within the electronic system can beobserved, analyzed and diagnosed within the target environment, there isno need to reproduce the failure in a model of the target environment,such as a testbench, for functional simulation or emulation.

Another exemplary feature pertains to the ability to communicate withhardware not instrumented. In some cases it may be important for a DICto communicate with other hardware that was not, or could not be,instrumented. Such communication can be done via dedicated ports of theDIC which can be connected to other devices in the electronic system, orto portions within the same device the DIC resides in. These ports canbe uni-directional or bi-directional. One example use of such ports isto communicate one or more trigger actions to another part of theelectronic system. Another example is to connect an interrupt signalfrom another device to the DIC. The interrupt signal can then be used asa trigger event inside the DIC.

Still another exemplary feature pertains to the ability of the HDL-basedhardware debugger to communicate with other systems. The HDL-basedhardware debugger is a software system which can communicate with othersoftware or hardware systems. The communications can allow transfer ofinformation into, or out of, the HDL-based hardware debugger. Forexample, an electronic system may be able to execute a software programand in such case the HDL-based hardware debugger can communicate with asoftware tool which can debug the software program. The HDL-basedhardware debugger may also communicate with hardware devices. Forexample, the HDL-based hardware debugger may send reset signals tohardware devices which connect to the DUT being debugged. In oneembodiment, the connection to other hardware devices is used to form aJTAG daisy-chain.

Yet another exemplary feature pertains to the ability to providehardware and/or software debugging. Some electronic systems have thecapability to execute a software program. Software tools exist to debugthe programmable hardware. It is advantageous for the designer of theelectronic system to have the capability to debug both the hardware andsoftware aspects of the electronic system concurrently. The HDL-basedhardware debugger can enable such a capability by debugging the hardwareof the electronic system and interfacing with software debugging tools.Interfacing with the software debugging tools can be done by usingcommunication methods previously described. The combined hardware andsoftware debugging system allows the designer to concurrently debug anentire electronic system including both hardware and software aspects.

The HDL-based hardware debugging can be used in many differentapplications. Different embodiments or implementations of the inventionmay be used in one or more of the following applications. Severalexample applications for the HDL-based hardware debugging are examinedbelow.

One exemplary application for the HDL-based hardware debugging isproperty checking at target speed. Functional simulation alone cannotguarantee that a HDL design meets a functional specification for the HDLdesign. Consequently, additional methods of gaining confidence in thecorrectness of the functionality of a HDL design are necessary. Adesigner can increase the level of confidence in the function of the HDLdesign by adding DIC which can detect when the HDL design is operatingcontrary to its functional specification. The DIC can provide propertychecks to assist the designer with identifying various conditions. Thedesigner might also build in property checks to handle anticipateddifficulties. Typically, during HDL-based hardware debugging, theproperty checks are activated and the electronic system is allowed torun in an environment and at a speed for which it is targeted. If theelectronic system operates in a manner that causes a property check toissue a trigger event, the designer has found a potential problem.

Software tools exist that formally prove that certain property checkswill never be triggered under any operating conditions of the design.Unfortunately, such tools may have tremendously long run-times sincethey must exhaustively analyze the design. The HDL-based hardwaredebugging approach does not have the problem of long run-times since allproperty checking is done in hardware that is running at target speed.

Another exemplary application for the HDL-based hardware debugging isHDL-based hardware debugging of errors in functional specifications.Some of the hardest functional failures to diagnose aremisunderstandings of the target environment the electronic system isdesigned to work in. Such misunderstandings may lead to mistakes in thefunctional specification of the electronic system. Hence, comparing theimplementation of the electronic system with its specification will notreveal such functional failure. However, the functional failure willbecome apparent when the electronic system is run in its targetenvironment. While conventional methods for debugging, such as logicanalyzers, can connect to accessible pins to monitor the operation ofthe electronic system within its target environment, these conventionalmethods do so only at a very low level of abstraction. In contrast, theHDL-based hardware debugging system according to the invention supportsanalysis, diagnosis and debugging of functional failures due to mistakesin the functional specification. First, there is no need to reproducethe problem in a testbench because the hardware itself is tested in itstarget environment. The ability to observe the HDL design while it isrunning in its target environment at the targeted speed allows thedesigner to immediately gather information about the electronic systemas well as the environment the system is running in. Second, theinformation gathered is related back to the HDL description, which isthe highest level of abstraction.

Another exemplary application for the HDL-based hardware debugging isHDL-based hardware debugging of design errors. Design errors stem frommismatches in the behavior of the HDL description written by thedesigner and the functional specification. Conventionally, such problemsare normally debugged by reproducing the observed error in a testbenchfor a functional simulator. Though functional simulation givesinformation at a very detailed level, creating and enhancing a testbenchto reproduce a functional failure is often a very tedious and difficulttask. In contrast, with HDL-based hardware debugging provided by theinvention, there is no need to reproduce the problem in a simulationmodel. By running the electronic system in the environment where thedesign error becomes apparent, sampling the desired portions of thesystem state, and analyzing the observed behavior which is related backto HDL identifiers, a functional failure can quickly be diagnosed.Having gained an understanding of the operation of the system, thedesigner then can use patching to apply a fix. Then, by re-running thepatched HDL design in the target environment, the designer can checkwhether the problem is fixed. In addition, the HDL-based hardwaredebugger can write out the sampled information in a format suitable fora functional simulator tool (check-pointing) so that the designer canuse their preferred analysis tools. The above-described check-pointingmechanism to forward the sampled information to functional simulationcan additionally be used.

Another exemplary application for the HDL-based hardware debugging isHDL-based hardware debugging of tool errors. Tool errors are functionalfailures which happen when, for example, a synthesis tool involved inHDL design process does not transform the HDL description into a correctfabricated design. Such errors manifest themselves as mismatches betweenthe functional specification and the functionality of the fabricateddesign, therefore debug techniques which work on the HDL descriptioncannot be used to debug such errors. However, since HDL-based hardwaredebugging works on the instrumented design which was produced by theerroneous tool, the symptoms are able to be displayed to the designerfor diagnosis.

Another exemplary application for the HDL-based hardware debugging isHDL-based hardware timing error analysis. Examples of timing errors inan HDL design are race conditions as well as setup and hold timeviolations in the hardware implementation. One symptom of a timing erroris that some registers do not store the correct, expected values. Thissymptom is easily detected using the method of checking for mismatchesbetween the functional simulation result and the values sampled by theDIC. When the designer examines the values of the circuitry that drivethe erroneous register, the cause for the symptom can be quicklydiagnosed. The impact of signal noise on the behavior of the electronicsystem can also be similarly analyzed and diagnosed.

Another exemplary application for the HDL-based hardware debugging isHDL-based hardware fault analysis. Faults stem from manufacturingdefects. When faults show up occasionally in a non-reproducible mannerfor one particular device or for only certain devices out of a batch ofother devices, diagnosis becomes very difficult. The HDL-based hardwaredebugging can be used to diagnose faults, and relate them back to HDLidentifiers to provide leads for the fault analysis. Detection of faultsis identical to the detection of timing errors and is done by checkingfor mismatches between functional simulation results and values sampledby the DIC. The ability to relate sample values to the HDL descriptionis a significant advantage since the designer can quickly identify theproblem. Once the problem is located in the HDL description, thedesigner can trace the problem all the way to the layout level todetermine the physical location of the defect or defects that caused thefault. The designer can then perform very precise design rule checks.The ability to limit the area for the design rule checks to theneighborhood of the defect location greatly reduces the effort. If thefault is caused by a design rule violation, it thus can be quickly foundand fixed. Knowing the context of the fault may also help to improve themanufacturing test program and/or improve the manufacturing yield.

Another exemplary application for the HDL-based hardware debugging isHDL-based critical-path analysis of hardware. To analyze the timing andidentify critical paths in the HDL design, the following is one methodthat can be used. Initially, the HDL design is run at the target speedin the target environment and using some predetermined triggerconditions, some predetermined signals are sampled and the value historyis stored. Then, iteratively, the frequency of one or more clock signalsis step-wise increased, the HDL design is run at the increased clockspeed/speeds while the HDL-based hardware debugger samples the very samesignals under the very same trigger conditions as performed in theinitial operation. For each iteration, the HDL-based hardware debuggerchecks for a mismatch between the current sampling values and theinitial sampling values. If a mismatch is detected, the HDL-basedhardware debugger informs the designer about the mismatch and thedesigner can then analyze the portion of the HDL design in which themismatch occurred. The portion of the HDL design in which the mismatchoccurred is likely to be a part of the critical path of the electronicsystem.

Another exemplary application for the HDL-based hardware debugging isanalysis, diagnosis and debugging of environmental errors. Environmentalfactors such as temperature, pressure, radiation, electromagneticfields, and aging effects may cause transient or permanent failures ofthe electronic system. Sometimes an electronic system works reliably inthe field for years until aging and/or environmental factors causefunctional failures. If parts of the electronic system have beeninstrumented, the invention can be used to diagnose the problem quicklyby looking for mismatches between the function of the electronic systemand sampled data taken from the fabricated design. If the electronicsystem has been instrumented with design patching, the electronic systemmight be patched to restore the proper behavior.

Another exemplary application for the HDL-based hardware debugging isHDL-based hardware power analysis. Power analysis of the electronicsystem needs to know about the realistic stimuli and transitions in theelectronic system to come up with an accurate estimation of the powerconsumption. In a hardware power analysis application according to theinvention, the system state of the HDL design running in the targetenvironment at target speed is sampled and stored by the HDL-basedhardware debugger and transformed into the proper format for describingsuch stimuli and transitions which can be processed by tools which arespecialized for power calculations.

Another exemplary application for the HDL-based hardware debugging isHDL-based hardware regression testing. For regression testing of changesto the hardware design, the invention can be used as follows. An initialversion of the instrumented HDL design, which itself has been tested andfound correct, is run with some predetermined trigger conditions andsome predetermined signals to be sampled. The sample values and theirhistory are stored as a “golden” reference file. Each HDL design whichincludes a design change is then run again using the same triggerconditions and sampling the same signals at the same events. TheHDL-based hardware debugger then checks for mismatches between thereference file and the current sampling data and issues warnings ifmismatches are detected. Accordingly, the design change that introducedthe mismatched behavior can be quickly isolated and fixed.

Another exemplary application for the HDL-based hardware debugging isHDL-based testbench optimization. The reference file of the hardwareregression testing application can be used as stimuli to create a newtestbench for functional simulation, or optimize an existing testbenchto more closely mimic the behavior of the target environment.

Another exemplary application for the HDL-based hardware debugging isHDL-based hardware device driver debugging. The debugging of aparticular device driver which interacts with the HDL design is similarto hardware/software co-debugging. The designer is thus able to see theeffects of the device driver on the HDL design it interacts withimmediately. In numerous applications of the invention, an electronicsystem shall be debugged after it has initially executed certain setupoperations. Having the electronic system execute the operations forsetup can be slow, tedious, and cumbersome. For example, an operatingsystem may be booted and many other device drivers may be loaded beforea particular device driver and the hardware used by it can be debugged.Now, if the designer has to iterate over the initialization many times,it is advantageous that the system state right after the initializationbe saved and restored before each iteration (e.g., system state database1930 of FIG. 19). The restoring will operate to bring the HDL designinto exactly the same post-initialization state.

Another exemplary application for the HDL-based hardware debugging isHDL-based software quality analysis in target hardware. The inventioncan also be used in regression testing and software quality assurance ofthe software that runs on the HDL design. If one or more softwareregression tests fail, the HDL-based hardware debugger can be used toquickly diagnose the failure.

Another exemplary application for the HDL-based hardware debugging isHDL-based embedded systems debugging. Software that runs on an embeddedCPU within the HDL design is able to be debugged by a software debugger.The software debugger can communicate with a HDL-based hardware debuggerthat debugs the hardware of the HDL design.

Still another exemplary application for the HDL-based hardware debuggingis in-field support. A common use of the HDL-based hardware debuggingsystem is to instrument an electronic system and then use the HHD 122 todebug the system. After debugging and fabrication, copies of thefabricated electronic system can be distributed to the designer'scustomers. At this point, the DIC 106 can be used in an in-field mode.In the in-field mode, the DIC 106 is used to diagnose failures thatoccur while the electronic system is being used by customers. The DIC106 still resides in the fabricated electronic system but the DIC'snormal state is disabled. It will be enabled if there is a problem withthe electronic system. In addition, a specially trained servicepersonnel can be sent to the customer's site. The personnel can attachthe instrumented electronic system to a portable host computer whichruns the HHD 122, activate the DIC 106, and debug the HDL design in thecustomer's environment. If the instrumented electronic system has beendesigned with a telecommunications link between the DIC 106 and the HHD122, remote debugging may avoid the need for service personnel to besent to the customer's site.

Yet another exemplary application for the HDL-based hardware debuggingis hardware performance monitoring. Often it is important for a hardwaresystem designer to monitor the performance of a hardware system in orderto understand and optimize the system. This can be done by a softwaresimulation of the system. Unfortunately, this has the drawback that itrequires a model of both the electronic system and of the environment itoperates in. By adding performance monitoring circuitry to the DIC 106of the electronic system, the designer can monitor the performance ofthe fabricated electronic system operating in its target environment andat its target speed. The process of adding the monitoring circuitrybegins with the instrumentor. The instrumentor displays the HDLdescription and enables the designer to add performance monitoringcircuitry which relates to the HDL description. During debugging, thedata from the performance monitoring circuitry is loaded from the DIC106 to the HHD 122 after a specified number of clock cycles or inresponse to some trigger event. The HHD 122 then displays the data forthe designer in the proper format. The circuit performance that can bemonitored by this added circuitry is quite broad; for example, a circuitperformance parameter in which there are events that can be counted—thenumber of times a First-In-First-Out (FIFO) queue overflows, a number ofcache misses, etc. Further, average values, such as average stack depth,can also be monitored by using more complex circuitry.

Portions of the invention are preferably implemented in software. Suchportions of the invention can also be embodied as computer readable codeon a computer readable medium. The computer readable medium is any datastorage device that can store data which can be thereafter be read by acomputer system. Examples of the computer readable medium includeread-only memory, random-access memory, CD-ROMs, magnetic tape, opticaldata storage devices, carrier waves. The computer readable medium canalso be distributed over a network coupled computer systems so that thecomputer readable code is stored and executed in a distributed fashion.

The many features and advantages of the present invention are apparentfrom the written description and, thus, it is intended by the appendedclaims to cover all such features and advantages of the invention.Further, since numerous modifications and changes will readily occur tothose skilled in the art, it is not desired to limit the invention tothe exact construction and operation as illustrated and described.Hence, all suitable modifications and equivalents may be resorted to asfalling within the scope of the invention.

1. A method for debugging a fabricated electronic system havinginstrumentation circuitry included therein, wherein the electronicsystem is described with an HDL description, said method comprising: aspart of the electronic system's design process: generating theinstrumentation circuitry at least by activating certain designvisibility, design patching or design control aspects of theinstrumentation circuit; determining configuration information of saidinstrumentation circuitry based on the certain activated designvisibility, design patching or design control aspects; after theelectronic system has been fabricated with the instrumentation circuitryto form an integrated circuit product, configuring the instrumentationcircuitry in accordance with the configuration information; receivingdebug data from the configured instrumentation circuitry operatingwithin the integrated circuit product; translating the debug data intoHDL-related debug information; and relating the HDL-related debuginformation to the HDL description.
 2. A method as recited in claim 1,wherein the HDL description is a high-level HDL description.
 3. A methodas recited in claim 2, wherein the HDL-related debug information isdescribed in a high-level HDL.
 4. A method as recited in claim 1,wherein said translating is performed automatically.
 5. A method asrecited in claim 1, wherein said method operates without any requirementfor a test bench.
 6. A method as recited in claim 1, wherein the debugdata includes at least status information or sampling data.
 7. A methodas recited in claim 1, wherein said activating is performed using agraphical user interface.
 8. A method as recited in claim 1, whereinsaid method further comprises: displaying the high-level HDL descriptionwith the HDL-related debug information related thereto.
 9. A method asrecited in claim 1, wherein the design control aspects include triggerconditions, and wherein said activating operates to enable a user to setone or more trigger conditions from the trigger conditions available byway of the instrumentation circuitry.
 10. A method as recited in claim1, wherein the electronic system comprises an integrated circuit.
 11. Amethod as recited in claim 1, wherein the electronic system comprises aprogrammable integrated circuit.
 12. A method as recited in claim 1,wherein the electronic system includes a hardware portion and a softwareportion, and wherein said method further comprises: interacting with asoftware debugger which debugs the software of the electronic system.13. A method as recited in claim 1, wherein said method furthercomprises: interacting with a functional simulator which simulates aportion of the electronic system.
 14. A method as recited in claim 1,wherein the electronic system is operated in its target environment andrunning at its target speed during said debugging.
 15. A method asrecited in claim 14, wherein the target environment includes real-timecharacteristics.
 16. A method as recited in claim 1, wherein whiledebugging the electronic system, the electronic system is operating inits target environment without interruption for the purpose ofdebugging.
 17. A method as recited in claim 1, wherein said debuggingoperates to identify at least one fault of the electronic system.
 18. Amethod as recited in claim 17, wherein the at least one fault isselected from the group consisting of: specification error, designerror, tool error, device driver error, timing error, manufacturingfault, and environment error.
 19. A method as recited in claim 1,wherein the instrumentation circuitry comprises design instrumentationcircuitry.
 20. A method for debugging a fabricated integrated circuitproduct having instrumentation circuitry included therein, theintegrated circuit product being designed with a high-level HDLdescription, said method comprising: as part of the integrated circuitproduct's design process: generating the instrumentation circuitry atleast by activating certain aspects of the instrumentation circuitry forexamining and/or modifying the integrated circuit product; determiningconfiguration information of said instrumentation circuitry based on thecertain activated aspects; after the integrated circuit product has beenfabricated: configuring the instrumentation circuitry in accordance withthe configuration information; receiving debug data from the configuredinstrumentation circuitry operating within the integrated circuitproduct; translating the debug data into HDL-related debug information;relating the HDL-related debug information to the high-level HDLdescription and thereafter retrieving circuit status information for theintegrated circuit product via the instrumentation circuitry; displayingstate information concerning the integrated circuit product based on theretrieved circuit status information.
 21. A method as recited in claim20, wherein the HDL-related debug information is described in ahigh-level HDL.
 22. A method as recited in claim 20, wherein saiddisplaying comprises: relating the state information to the high-levelHDL description; and displaying the high-level HDL description of theintegrated circuit product with the state information related thereto.23. A method as recited in claim 20, wherein the state informationincludes signal values for signals, and wherein said relating operatesto relate the signal values to HDL identifiers within the high-level HDLdescription that correspond to the signals.
 24. An article ofmanufacture including program code which, when executed by a machine,causes the machine to perform method for debugging a fabricatedelectronic system having instrumentation circuitry included therein,wherein the electronic system is described with an HDL description, saidmethod comprising: as part of the electronic system's design process:generating the instrumentation circuitry at least by activating certaindesign visibility, design patching or design control aspects of theinstrumentation circuitry; determining configuration information of saidinstrumentation circuitry based on the certain activated designvisibility, design patching or design control aspects; after theelectronic system has been fabricated with the instrumentation circuitryto form an integrated circuit product, configuring the instrumentationcircuitry in accordance with the configuration information; receivingdebug data from the configured instrumentation circuitry operatingwithin the integrated circuit product; translating the debug data intoHDL-related debug information; and relating the HDL-related debuginformation to the HDL description.
 25. A article of manufacture asrecited in claim 24, wherein the HDL description is a high-level HDLdescription.
 26. A article of manufacture as recited in claim 25,wherein the HDL-related debug information is described in a high-levelHDL.
 27. A article of manufacture as recited in claim 24, wherein saidtranslating is performed automatically.
 28. A article of manufacture asrecited in claim 24, wherein said method operates without anyrequirement for a test bench.
 29. A article of manufacture as recited inclaim 24, wherein the debug data includes at least status information orsampling data.
 30. A article of manufacture as recited in claim 23,wherein said activating is performed using a graphical user interface.31. A article of manufacture as recited in claim 24, wherein said methodfurther comprises: displaying the high-level HDL description with theHDL-related debug information related thereto.
 32. A article ofmanufacture as recited in claim 24, wherein the design control aspectsinclude trigger conditions, and wherein said activating operates toenable a user to set one or more trigger conditions from the triggerconditions available by the instrumentation circuitry.
 33. A article ofmanufacture as recited in claim 24, wherein the electronic systemcomprises an integrated circuit.
 34. A article of manufacture as recitedin claim 24, wherein the electronic system comprises a programmableintegrated circuit.
 35. A article of manufacture as recited in claim 24,wherein the electronic system includes a hardware portion and a softwareportion, and wherein said method further comprises: interacting with asoftware debugger which debugs the software of the electronic system.36. A article of manufacture as recited in claim 24, wherein said methodfurther comprises: interacting with a functional simulator whichsimulates a portion of the electronic system.
 37. A article ofmanufacture as recited in claim 24, wherein the electronic system isoperated in its target environment and running at its target speedduring said debugging.
 38. A article of manufacture as recited in claim37, wherein the target environment includes real-time characteristics.39. A article of manufacture as recited in claim 24, wherein whiledebugging the electronic system, the electronic system is operating inits target environment without interruption for the purpose ofdebugging.
 40. A article of manufacture as recited in claim 24, whereinsaid debugging operates to identify at least one fault of the electronicsystem.
 41. A article of manufacture as recited in claim 40, wherein theat least one fault is selected from the group consisting of:specification error, design error, tool error, device driver error,timing error, manufacturing fault, and environment error.
 42. A articleof manufacture as recited in claim 24, wherein the instrumentationcircuitry comprises design instrumentation circuitry.
 43. An article ofmanufacture including program code which, when executed by a machine,causes the machine to perform a method for debugging a fabricatedintegrated circuit product having instrumentation circuitry includedtherein, the integrated circuit product being designed with a high-levelHDL description, said method comprising: as part of the integratedcircuit product's design process: generating the instrumentationcircuitry at least by activating certain aspects of the instrumentationcircuitry for examining and/or modifying the integrated circuit product;determining configuration information of said instrumentation circuitrybased on the certain activated aspects; after the integrated circuitproduct has been fabricated: configuring the instrumentation circuitryin accordance with the configuration information; receiving debug datafrom the configured instrumentation circuitry operating within theintegrated circuit product; translating the debug data into HDL-relateddebug information; relating the HDL-related debug information to thehigh-level HDL description and thereafter retrieving circuit statusinformation for the integrated circuit product via the instrumentationcircuitry; displaying state information concerning the integratedcircuit product based on the retrieved circuit status information.
 44. Aarticle of manufacture as recited in claim 43, wherein the HDL-relateddebug information is described in a high-level HDL.
 45. A article ofmanufacture as recited in claim 43, wherein said displaying comprises:relating the state information to the high-level HDL description; anddisplaying the high-level HDL description of the integrated circuitproduct with the state information related thereto.
 46. A article ofmanufacture as recited in claim 43, wherein the state informationincludes signal values for signals, and wherein said relating operatesto relate the signal values to HDL identifiers within the high-level HDLdescription that correspond to the signals.